<commit_before>;;;;; tré – Copyright (c) 2008–2012 <NAME> <<EMAIL>>

(defun make-overlayed-std-macro-expander (tr expander-name)
  (with (e       (define-expander expander-name)
         mypred  (expander-pred e)
		 mycall  (expander-call e))
    (= (expander-pred e) (lx (tr mypred)
						   (fn | (funcall ,mypred _)
                                 (? (transpiler-only-environment-macros? ,tr)
				 		            (%%env-macrop _)
				 		            (%%macrop _))))
   		  (expander-call e) (lx (tr mypred mycall)
								(fn ? (funcall ,mypred _) (funcall ,mycall _)
                                      (transpiler-only-environment-macros? ,tr) (%%env-macrocall _)
                                      (%%macrocall _))))))

(defun transpiler-make-std-macro-expander (tr)
  (let expander-name ($ (transpiler-name tr) '-standard)
    (= (transpiler-std-macro-expander tr) expander-name)
    (make-overlayed-std-macro-expander tr expander-name)))

(defmacro define-transpiler-std-macro (tr name &rest args-and-body)
  `(progn
     (transpiler-add-inline-exception ,tr ',name)
     (define-expander-macro ,(transpiler-std-macro-expander (eval tr)) ,name ,@args-and-body)))

(defun transpiler-macroexpand (tr x)
  (with-temporary *=-function?* (transpiler-=-function? tr)
    (expander-expand (transpiler-std-macro-expander ,tr) x)))

(defmacro transpiler-wrap-invariant-to-binary (definer op len replacement combinator)
  `(,definer ,op (&rest x)
     (transpiler-add-inline-exception *current-transpiler* ,(list 'quote replacement))
     (? (< ,len (length x))
        (cons ',combinator (mapcar (fn `(,replacement ,,@(subseq x 0 ,(1- len)) ,,_)) (subseq x ,(1- len))))
        (cons ',replacement x))))
<commit_msg>Print definitions.<commit_after>;;;;; tré – Copyright (c) 2008–2012 <NAME> <<EMAIL>>

(defun make-overlayed-std-macro-expander (tr expander-name)
  (with (e       (define-expander expander-name)
         mypred  (expander-pred e)
		 mycall  (expander-call e))
    (= (expander-pred e) (lx (tr mypred)
						   (fn | (funcall ,mypred _)
                                 (? (transpiler-only-environment-macros? ,tr)
				 		            (%%env-macrop _)
				 		            (%%macrop _))))
   		  (expander-call e) (lx (tr mypred mycall)
								(fn ? (funcall ,mypred _) (funcall ,mycall _)
                                      (transpiler-only-environment-macros? ,tr) (%%env-macrocall _)
                                      (%%macrocall _))))))

(defun transpiler-make-std-macro-expander (tr)
  (let expander-name ($ (transpiler-name tr) '-standard)
    (= (transpiler-std-macro-expander tr) expander-name)
    (make-overlayed-std-macro-expander tr expander-name)))

(defmacro define-transpiler-std-macro (tr name &rest args-and-body)
  (print-definition `(define-transpiler-std-macro ,tr ,name ,args-and-body.))
  `(progn
     (transpiler-add-inline-exception ,tr ',name)
     (define-expander-macro ,(transpiler-std-macro-expander (eval tr)) ,name ,@args-and-body)))

(defun transpiler-macroexpand (tr x)
  (with-temporary *=-function?* (transpiler-=-function? tr)
    (expander-expand (transpiler-std-macro-expander ,tr) x)))

(defmacro transpiler-wrap-invariant-to-binary (definer op len replacement combinator)
  `(,definer ,op (&rest x)
     (transpiler-add-inline-exception *current-transpiler* ,(list 'quote replacement))
     (? (< ,len (length x))
        (cons ',combinator (mapcar (fn `(,replacement ,,@(subseq x 0 ,(1- len)) ,,_)) (subseq x ,(1- len))))
        (cons ',replacement x))))

{'fraction_non_alphanumeric': 0.16302186878727634, 'fraction_numerical': 0.0062482249360976995, 'mean_word_length': 2.6802507836990594, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 6, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4369771', 'n_tokens_mistral': 1332, 'n_tokens_neox': 1212, 'n_words': 260}