Questions tagged [syntax-object]

In many varieties of Scheme, including R6RS and Racket, the input and output of a macro transformer (i.e., source and replacement forms) are represented as syntax objects.

In many varieties of Scheme, including R6RS and Racket, the input and output of a macro transformer (i.e., source and replacement forms) are represented as syntax objects. A syntax object contains symbols, lists, and constant values (such as numbers) that essentially correspond to the quoted form of the expression, as well as source code location.

3 questions
7
votes
1 answer

What exactly is the purpose of syntax objects in scheme?

I am trying to write a small scheme-like language in python, in order to try to better understand scheme. The problem is that I am stuck on syntax objects. I cannot implement them because I do not really understand what they are for and how they…
Matt
  • 21,026
  • 18
  • 63
  • 115
3
votes
1 answer

In Racket or Scheme, is there any way to convert an ellipsis syntax object to a list of syntax objects?

For example: (syntax-case #'(a b c d) () ((x ...) (list #'x ...)) In the example, (list #'x ...) obviously does not work, but what can I do to output the equivalent of (list #'a #'b #'c #'d)?
Matt
  • 21,026
  • 18
  • 63
  • 115
0
votes
1 answer

PDF Inline Image XObject Source Unknown error

Getting error in PDF-Online.com that 'The name Im1 of a xobject resource is unknown.' in the following PDF below. In Object 41 I establish the XObject 6 with the Image Name of Im1. When I view this file in Adobe it displays an error message box that…
jdcasazza
  • 11
  • 3