compiler-theory
How to implement call by name in C#?
Can anyone tell me how I can implement Call开发者_开发百科 By Name in C#?Pass a lambda function instead of a value.C# is eagerly evaluated so in order to defer execution so that each site re-evaluates[详细]
2023-01-22 10:33 分类:问答Interesting Compiler Projects
I am looking at a semester long project in compilers that could also evolve into my graduate thesis. I do not have much experience in this field (I have written a small \"translator\" for Pascal as pa[详细]
2023-01-21 01:28 分类:问答how to read the header block gcc compiler put to .o .a and an executable
I\'d like to read the header block gcc put to the beginning of all .o .a and executables. In those days, on Solaris, there was an util开发者_JAVA技巧ity for this purpose. On linux, is similar utility[详细]
2023-01-17 05:19 分类:问答Scala "<-" for comprehension
I have found that Scala always has a \"natural explanation\" to anything. Always something like \"ohh, but that\'s just a function being called on this and that object with this and that parameter\".[详细]
2023-01-17 01:50 分类:问答What are the key design choices to make a wicked fast compiler?
I want to know how to design a compiler that compiles very, very quickly. First, let me head off some obvious misunderstandings of my question:[详细]
2023-01-16 12:46 分类:问答What is an example of a lexical error and is it possible that a language has no lexical errors?
for our compiler 开发者_C百科theory class, we are tasked with creating a simple interpreter for our own designed programming language. I am using jflex and cup as my generators but i\'m a bit stuck wi[详细]
2023-01-11 08:46 分类:问答Getting tree construction with ANTLR
As asked and answered in Removing Left Recursion in ANTLR , I could remove the left recursion E -> E + T|T[详细]
2023-01-03 08:39 分类:问答Indentation control while developing a small python like language
I\'m developing a small python like language using flex, byacc (for lexical and parsing) and C++, but i have a few questions regarding scope control.[详细]
2022-12-29 04:40 分类:问答Determining the maximum stack depth
Imagine I have a stack-based toy language that comes with the operations Push, Pop, Jump and If. I have a program and its input is the toy language. For instance I get the sequence[详细]
2022-12-28 18:19 分类:问答How does the compiler detect duplicate definition across translation units
How does a compiler detect duplicate definition across translation unit. Suppose there were a extern const variable declaration in an header file.If this header file was used in more than one translat[详细]
2022-12-28 06:56 分类:问答