25:
637:
a match is recognized the code body of that macro is processed to produce output text, error messages, or create a constructed line that is submitted for further template matching. So the process is fully recursive and quite powerful in its capabilities for text transformation. In fact, it can be used to implement a programming language compiler.
139:
A macro processor is a program that copies a stream of text from one place to another, making a systematic set of replacements as it does so. Macro processors are often embedded in other programs, such as assemblers and compilers. Sometimes they are standalone programs that can be used to process any
636:
Stage2 was created by Prof
William Waite at the University of Colorado in the late sixties as a major component of his mobile programming system, MPS. Stage2 uses a pattern matching algorithm to match input lines of text against a set of templates. Each template is the first line of a macro and when
321:
Another attempt was the GMP (General Macro
Processor) developed in the mid-1970s by M Boule in the DLB/GC department of the CII Company along ideas from R.J. Chevance. Tested in association with the Bordeaux I University the first version ran the SIRIS8/IRIS80 System. It was ported to mini6 systems
418:
m5 is a general-purpose macro processor written by
William A. Ward, Jr. Unlike many macroprocessors, m5 does not directly interpret its input. Instead it uses a two-pass approach in which the first pass translates the input to an awk program, and the second pass executes the awk program to produce
228:. This too is a general purpose macro processor, but it processes input a line at a time, matching each line against specified patterns; it is notable in that it is independent of character set, requiring only that the digits 0-9 are contiguous and in that order (a condition not met by some of the
503:
minimac is a minimalist general purpose macro processor. It operates as a character stream filter, recursively expanding macros as they are encountered. It is unusual for a macro processor in that it uses an explicit argument stack, and user functions are defined by concatenation (similar to the
143:
Macro processors have been used for language expansion (defining new language constructs that can be expressed in terms of existing language components), for systematic text replacements that require decision making, and for text reformatting (e.g. conditional extraction of material from an
519:
aa_macro is an open-source character-stream-based text processing language written in Python. Text is processed in a left-to-right, inside-to-outside manner. A selection of pre-defined built-in functions provide fundamental processing mechanisms that may be used directly or as elements of
305:
is a recursive, interpretive language designed primarily for string manipulation, text editing, macro definition and expansion, and other applications generally classified as systems programming. It was developed in 1968 by Steven Caine and E. Kent Gordon at the
453:
programming language. Beyond simple macro replacement, it allows evaluating arbitrary JavaScript expressions and executing JavaScript code. It can also load JSON data models for more complex data-driven text processing tasks.
326:
for this family of computers. The GMP processor used C2-Chomsky grammars to define the syntax of macros and used an imperative language to execute computations and proceed to macro expansion.
209:). This was developed as part of PhD research by a Cambridge postgraduate, Peter J. Brown. ML/I operates on a character stream, and requires no special format for its input, nor any special
395:
gpp is another general macro processor written by Denis Auroux. It resembles a C preprocessor, but has more general semantics and allows for customized syntax (for instance,
434:
programming language. In addition to simple macro replacement it allows evaluation of arbitrary Python expressions and execution of python code making pyexpander
520:
user-defined styles. The language is user extensible, and wtfm, an open-source web-based document preparation wrapper for the language, is available.
624:
42:
89:
61:
868:
68:
75:
376:
gema is a contextual macro processor based on pattern matching, written by David N. Gray. It replaces/enhances the concept of
281:
is a string processing language which is capable of doing most of the pre-processing which can be done by a macro processor.
57:
380:
by contexts. Contexts roughly corresponds to named sets of patterns. As a consequence, macros in gema closely resemble an
307:
108:
490:
46:
486:
431:
381:
252:
82:
621:"Translation of 8080 Code to 8086 - Microsoft Translation of 8080 Code to 8086 and Other 16-Bit Processors"
505:
210:
620:
256:
302:
291:
XPOP was another attempt at a general macro processing language by Mark
Halpern at IBM in the 1960s.
532:
233:
184:). This was developed at the University of Cambridge, UK, in the mid 1960s, under the direction of
133:
16:
Macro processor that is not tied to or integrated with a particular language or piece of software.
469:(and more generally Markdown and reStructuredText). PP implements: Macros, literate programming,
35:
666:
Farber, D. J., 635 Assembly System - GAP. Bell
Telephone Laboratories Computation Center (1964).
337:
229:
649:
136:
processor that is not tied to or integrated with a particular language or piece of software.
556:
185:
8:
435:
798:
377:
323:
601:
572:
822:
345:
248:
349:
199:
One particularly important general purpose macro processor was (and still is)
862:
577:
560:
264:
842:
128:
605:
726:"Welcome to pyexpander's documentation! — pyexpander 1.7.0 documentation"
592:
Waite, William M. (July 1970). "The mobile programming system: STAGE2".
774:
482:
450:
260:
449:
Text
Assembler is a general-purpose text/macro processor based on the
725:
24:
474:
470:
700:
749:
478:
247:
Early macro processor developed at AT&T Bell
Laboratories by
466:
404:
278:
151:
676:
430:
pyexpander is a general-purpose macro processor based on the
400:
535: – Rule for substituting a set input with a set output
341:
224:
A contemporary of ML/I was STAGE2, part of
William Waite's
201:
145:
396:
775:"PP - A generic Preprocessor (with Pandoc in mind)"
49:. Unsourced material may be challenged and removed.
656:(2nd, revised ed.). CUP Archive. p. 254.
176:One of the earliest macro processors was GPM (the
860:
310:. It is derived, primarily, from GAP and GPM.
255:and Andrew Hall. It was influenced by GPM and
152:Examples of general purpose macro processors
322:and was the main component involved in the
576:
109:Learn how and when to remove this message
555:
618:
465:PP is a text preprocessor designed for
365:, Vol. 14, pp. 519–531, Jun. 1984
861:
619:Britten, Charles Randyl (2020-06-26).
600:(7). New York, NY, USA: ACM: 415–421.
591:
551:
549:
648:
47:adding citations to reliable sources
18:
869:Programming language implementation
13:
772:
660:
561:"A General Purpose Macrogenerator"
546:
308:California Institute of Technology
14:
880:
363:Software: Practice and Experience
58:"General-purpose macro processor"
213:characters to introduce macros.
23:
835:
815:
791:
766:
627:from the original on 2021-07-23
123:general-purpose macro processor
34:needs additional citations for
742:
718:
693:
669:
642:
612:
585:
407:-like scripts are definable).
180:General Purpose Macrogenerator
1:
539:
236:character codes of the era).
7:
526:
155:
10:
885:
730:pyexpander.sourceforge.net
477:and ditaa diagrams, Bash,
594:Communications of the ACM
226:Mobile Programming System
750:"akiwi - Text Assembler"
533:Macro (computer science)
578:10.1093/comjnl/8.3.225
606:10.1145/362686.362691
557:Strachey, Christopher
773:Delord, Christophe.
681:gema.sourceforge.net
186:Christopher Strachey
43:improve this article
705:logological.org/gpp
378:regular expressions
263:, it was ported to
419:the final output.
207:Macro Language One
524:
523:
340:was designed for
324:system generation
259:. Implemented in
119:
118:
111:
93:
876:
853:
852:
850:
849:
839:
833:
832:
830:
829:
819:
813:
812:
810:
809:
795:
789:
788:
786:
785:
770:
764:
763:
761:
760:
746:
740:
739:
737:
736:
722:
716:
715:
713:
711:
697:
691:
690:
688:
687:
673:
667:
664:
658:
657:
654:Macro Processors
646:
640:
639:
633:
632:
616:
610:
609:
589:
583:
582:
580:
565:Computer Journal
559:(October 1965).
553:
182:
181:
156:
127:general purpose
114:
107:
103:
100:
94:
92:
51:
27:
19:
884:
883:
879:
878:
877:
875:
874:
873:
859:
858:
857:
856:
847:
845:
841:
840:
836:
827:
825:
821:
820:
816:
807:
805:
797:
796:
792:
783:
781:
771:
767:
758:
756:
754:www.akiwi.co.uk
748:
747:
743:
734:
732:
724:
723:
719:
709:
707:
699:
698:
694:
685:
683:
675:
674:
670:
665:
661:
647:
643:
630:
628:
617:
613:
590:
586:
554:
547:
542:
529:
443:Text Assembler
436:Turing complete
346:Brian Kernighan
249:Douglas McIlroy
179:
178:
154:
115:
104:
98:
95:
52:
50:
40:
28:
17:
12:
11:
5:
882:
872:
871:
855:
854:
834:
814:
790:
765:
741:
717:
692:
668:
659:
641:
611:
584:
571:(3): 225–241.
544:
543:
541:
538:
537:
536:
528:
525:
522:
521:
517:
514:
510:
509:
501:
499:
495:
494:
463:
460:
456:
455:
447:
444:
440:
439:
428:
425:
421:
420:
416:
413:
409:
408:
393:
390:
386:
385:
374:
371:
367:
366:
360:
358:
354:
353:
350:Dennis Ritchie
335:
332:
328:
327:
319:
316:
312:
311:
300:
297:
293:
292:
289:
287:
283:
282:
276:
273:
269:
268:
265:Version 2 Unix
245:
242:
238:
237:
222:
219:
215:
214:
197:
194:
190:
189:
174:
171:
167:
166:
163:
160:
153:
150:
140:kind of text.
117:
116:
99:September 2011
31:
29:
22:
15:
9:
6:
4:
3:
2:
881:
870:
867:
866:
864:
844:
838:
824:
818:
804:
803:freshmeat.net
800:
794:
780:
776:
769:
755:
751:
745:
731:
727:
721:
706:
702:
696:
682:
678:
672:
663:
655:
651:
645:
638:
626:
622:
615:
607:
603:
599:
595:
588:
579:
574:
570:
566:
562:
558:
552:
550:
545:
534:
531:
530:
518:
515:
512:
511:
507:
502:
500:
497:
496:
492:
488:
484:
480:
476:
472:
468:
464:
461:
458:
457:
452:
448:
445:
442:
441:
437:
433:
429:
426:
423:
422:
417:
414:
411:
410:
406:
402:
398:
394:
391:
388:
387:
384:description.
383:
379:
375:
372:
369:
368:
364:
361:
359:
356:
355:
351:
347:
343:
339:
336:
333:
330:
329:
325:
320:
317:
314:
313:
309:
304:
301:
298:
295:
294:
290:
288:
285:
284:
280:
277:
274:
271:
270:
266:
262:
258:
254:
253:Robert Morris
250:
246:
243:
240:
239:
235:
231:
227:
223:
220:
217:
216:
212:
208:
204:
203:
198:
195:
192:
191:
187:
183:
175:
172:
169:
168:
164:
161:
158:
157:
149:
147:
141:
137:
135:
131:
130:
124:
113:
110:
102:
91:
88:
84:
81:
77:
74:
70:
67:
63:
60: –
59:
55:
54:Find sources:
48:
44:
38:
37:
32:This article
30:
26:
21:
20:
846:. Retrieved
837:
826:. Retrieved
817:
806:. Retrieved
802:
793:
782:. Retrieved
778:
768:
757:. Retrieved
753:
744:
733:. Retrieved
729:
720:
708:. Retrieved
704:
695:
684:. Retrieved
680:
671:
662:
653:
644:
635:
629:. Retrieved
614:
597:
593:
587:
568:
564:
362:
225:
206:
200:
177:
165:Description
142:
138:
129:preprocessor
126:
122:
120:
105:
96:
86:
79:
72:
65:
53:
41:Please help
36:verification
33:
650:Cole, A. J.
508:language).
424:pyexpander
848:2017-11-24
828:2017-11-24
823:"aa_macro"
808:2017-04-21
784:2017-10-17
759:2017-04-21
735:2017-04-21
686:2017-04-21
631:2021-11-28
540:References
483:PowerShell
451:JavaScript
261:FORTRAN IV
69:newspapers
799:"minimac"
779:cdsoft.fr
710:April 21,
513:aa_macro
493:scripts.
863:Category
652:(1981).
625:Archived
527:See also
498:minimac
475:PlantUML
471:GraphViz
491:Haskell
272:SNOBOL
218:STAGE2
148:file).
83:scholar
843:"wtfm"
677:"Gema"
487:Python
467:Pandoc
432:Python
405:Prolog
403:, and
357:ELENA
318:1970s
279:SNOBOL
275:1960s
244:1960s
221:1960s
196:1960s
173:1960s
85:
78:
71:
64:
56:
701:"GPP"
516:2017
506:Forth
462:2016
446:2014
427:2011
415:1999
401:XHTML
392:1996
373:1995
370:gema
334:1977
299:1968
286:XPOP
230:6-bit
193:ML/I
162:Year
159:Name
134:macro
132:is a
90:JSTOR
76:books
712:2017
489:and
389:GPP
382:EBNF
348:and
342:Unix
315:GMP
296:TTM
257:TRAC
232:and
211:flag
202:ML/I
170:GPM
146:HTML
62:news
602:doi
573:doi
479:Cmd
459:PP
412:M5
397:TeX
344:by
331:M4
303:TTM
241:M6
234:BCD
125:or
45:by
865::
801:.
777:.
752:.
728:.
703:.
679:.
634:.
623:.
598:13
596:.
567:.
563:.
548:^
485:,
481:,
473:,
438:.
399:,
352:.
338:m4
267:.
251:,
188:.
121:A
851:.
831:.
811:.
787:.
762:.
738:.
714:.
689:.
608:.
604::
581:.
575::
569:8
205:(
112:)
106:(
101:)
97:(
87:·
80:·
73:·
66:·
39:.
Text is available under the Creative Commons Attribution-ShareAlike License. Additional terms may apply.