summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
...
* moved ragel/* to src/Adrian Thurston2020-03-14244-3229/+221
|
* removed the colm tests, source runtests from colm packageAdrian Thurston2020-03-145601-2216661/+16
|
* ragel is again forked from colm, leaving behind libfsm and rlhcAdrian Thurston2020-03-08171-76135/+128
| | | | | | Plan is to give colm language-independent code generation features taken from ragel. We first merged ragel and colm, and then forked ragel off, leaving behind what will go into colm. Ragel gets a dependency on the colm package.
* test suite: various updates to allow running on OSXAdrian Thurston2020-03-078-10/+16
|
* Merge pull request #107 from computerquip/standalone-executablesAdrian D. Thurston2020-02-243-3/+32
|\ | | | | add flag to support standalone executables
| * add flag to support standalone executablesZachary Lund2020-02-153-3/+32
|/
* osx linker will not accept -rpath=X, must use a space (achieved with a comma)Adrian Thurston2020-01-311-1/+1
|
* eliminate usage of --transform from tar -cf commandAdrian Thurston2020-01-311-2/+3
| | | | | | | | Rather than using the --transform argument to tar to remove the .pack extension from the individual files when creating the tarball, simply rename the files after unpacking. The individual files will then live in the tarball with the .pack extension, but that's okay. The --transform argument is not available on osx tar.
* added config.h.in~ to gitignoreAdrian Thurston2020-01-311-0/+1
|
* use glibtoolize on darwinAdrian Thurston2020-01-311-1/+9
|
* colm: modified calling convention for colm wrapperAdrian Thurston2020-01-0918-177/+194
| | | | | | | | Changed the calling convention for colm-wrap (formerly colm-pack) so that we can substitute the colm program, once packing is implemented there. Makes the new wrapper args compatible with the existing args for the colm binary. refs #85
* ragel: don't send \n before closing }%%Adrian Thurston2020-01-0913-13/+13
| | | | | Sending a newline means a missing ; results in the error getting attributed to the next line. refs #103
* colm: use a string's location (if present) when pushing to an inputAdrian Thurston2020-01-096-44/+46
| | | | refs #103
* colm: added outdent check on literal concatenationsAdrian Thurston2020-01-092-45/+97
| | | | | | | | | | | | | | | | The colm language has an ambiguity between literal concatenations and distinct statements, where the first ends in string/accum/cons/pat and the second is a bare send. For example: match P "a b c d" "e f g h" Warn on some of these by checking for an outdent (relative to the first component) on top level concatenations. If the user does not outdent between separate intended statements we cannot help with this check. refs #95
* colm: eliminated the range-crosses-zero hack needed when alphtype was signedAdrian Thurston2020-01-082-29/+4
| | | | | | | In 900189a4d23f0180970f22479f44377973a2d330 we added an option to hack the parsing of hex literals to allow ranges that cross zero. This was necessary when alphtype was signed. Moving to an unsigned type eliminates the need for this.
* colm: using an unsigned char as alph type in scannerAdrian Thurston2020-01-0815-96/+122
| | | | | | | | | | | | | Switching to unsigned so we can reference chars with the high bit set in the way that is common when discussing utf and unicode: using hex chars. Negative values are really uncomfortable and don't lend themselves to specifying ranges. This change is for the parser and stream/input code only. The collected tree data still uses char, which makes it convenient to extract the data from a top-down or bottom-up load. If we change the tree type we need to cast the pointers all over the loading code. refs #104 refs #97 refs #81
* colm: removed flags field from the kid structAdrian Thurston2020-01-082-7/+9
| | | | | We eliminated the use of this field some time ago, but never removed the field from the struct.
* suppress unused variable warning for when --disable-debug is usedAdrian Thurston2020-01-071-3/+13
|
* eliminated unused var warning when sizeof(int) != sizeof(long)Adrian Thurston2020-01-051-0/+2
| | | | refs #97
* fixed the variable capture in read_word on 32 bit systemsAdrian Thurston2020-01-051-6/+6
| | | | refs #97
* some function renaming and old code removal to elim warningsAdrian Thurston2020-01-054-345/+5
| | | | refs #97
* merge branch 'literal-concatenation'Adrian Thurston2020-01-032-34/+51
|\ | | | | | | | | Pushing forward with the literal-concatenation patch. This brings back lists of literals strings at the top level of strings, constructors and patterns.
| * colm: testing a new grammar where string concatenations are allowedAdrian Thurston2019-12-282-34/+51
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit brings back string concatenations in match/cons/string literals at the top level. It does not bring back concatenation of [] lists. For example, you can write: match Foo "hi "there BUT NOT: match Foo [Hi] [There] The concatenation (of both forms) was removed when bare sends were added, due to the ambiguity created. However, removing these concatenations has proven quite annoying. This change re-introduces the ambiguity, which maybe we should do something about by detecting when it is likely via mis-alignments of the strings, or making some other change to sends. refs #95
* | colm: folding some long lines in input and stream implementationsAdrian Thurston2020-01-032-35/+70
| |
* | colm-pack: don't try to tar up results when colm failesAdrian Thurston2020-01-031-1/+3
| | | | | | | | refs #85
* | updated colm-pack wrapper: parse args first then switch on outputAdrian Thurston2020-01-032-50/+51
| | | | | | | | | | | | | | | | | | | | Other updates to colm/Makefile.am: don't depend on gen dir to have it built, causes rebuilding when new files go in. Do it the old way using mkdir -p gen in the rule that puts files there. Also colm-pack.sh needs to go into EXTRA_DIST. refs #85
* | using a wrapper script to achieve one output per runAdrian Thurston2020-01-0230-83/+240
| | | | | | | | | | | | | | Using a wrapper around colm that tars up output files into a pack. The same wrapper can be used to extract the output files one at a time. Using -p to specify the pack file name. Using the wrapper in the building of colm and ragel. refs #85
* | added missing open/close block to BREAK and NBREAKAdrian Thurston2020-01-012-4/+60
| | | | | | | | refs #102
* | containing package versioned X and sub-packages X.YAdrian Thurston2019-12-313-11/+12
| | | | | | | | | | Containing package (colm-suite) will start at version 1. This first release will contain colm 0.14 and ragel 7.0. refs #101
* | colm: implemented IN_SET_RHS_VAL_WC and stubbed relatedAdrian Thurston2019-12-304-0/+61
| | | | | | | | | | Was not possible to set a named RHS element in a tree. Added the _WC version and stubbed the others.
* | ragel: unified Variable and GotoLabel reference functionsAdrian Thurston2019-12-3015-51/+49
| |
* | some whitespace fixes: spaces to tabsAdrian Thurston2019-12-293-9/+9
| |
* | Possible fix for issue discovered by clang 9.01mingodad2019-12-291-1/+1
| |
* | Fix for compiling with clang 9.01 on androidmingodad2019-12-2923-111/+119
| |
* | colm: updated hello_world and assign examplesAdrian Thurston2019-12-293-11/+17
| | | | | | | | | | | | | | | | | | | | | | Removed the string concatenation from hello world examples (even though we want to bring it back eventually). Updated assign example so it does not use named lexical regions. Also removed the overlap between id and number, which resulted in the id form of number never matching. Added some error handling. refs #94
* | colm testing: default expected output, report compilation failuresAdrian Thurston2019-12-292-6/+12
| | | | | | | | | | | | | | | | | | | | 1. If there are no expected output sections then default a section to empty and run at least one pass. 2. If the compilation failed then report this explicitly in the diff. This avoids the case accidentally passing due to an empty expected output. refs #96
* | colm: fixes for backtracking in constructors and patternsAdrian Thurston2019-12-292-3/+66
| | | | | | | | | | Backtracking in across literal blocks had a minor fault in constructors and was fully missing from patterns. Both fixed with this commit. refs #86
* | colm rewriting: break when we create a new prodAdrian Thurston2019-12-282-1/+4
|/ | | | The implementation allows only one value returned so we must break.
* ragel julia: upgrades tests to 1.0 of julia languageAdrian Thurston2019-12-284-19/+35
| | | | | | | | | | | | | | | | | The string class is no longer containing uints, now signed. Convert the input strings to vectors of uint8s, since the julia code generator currently supports only uint8. Use numerical representation of 'a' since we have no way to separate single lits from double lits and cast them in the julia test case translator Don't try to construct AbstractString, use String. Array constructor Array{Int, 1}(undef, 20) must take undef as first arg. Verify we have julia 1.0 or later in configure script. refs #91
* ragel testing: try gdc-8 down through gdc-5Adrian Thurston2019-12-271-1/+11
|
* ragel: check that javac worksAdrian Thurston2019-12-271-0/+18
| | | | | If ulimit -a is used, javac may not run. Added a configure check to verify it runs. refs #92
* colm: proper implementation of both left and right recursion in c++Adrian Thurston2019-12-279-50/+66
| | | | | Not doing these in colm. Relying on th existing correct implementation. Also removed the naming conflict between left and right recursion.
* colm rewriting: newly generated prods should go above where they are createdAdrian Thurston2019-12-271-40/+48
| | | | | | | | | | | Redid the sublist implementation in colm such that the new produciton is placed immediately above the place where it it was first referenced. Works better in the face of of namesapce usage Also removed the repeat implementations. These are already correct in the C++ program so no sense in redoing them. This is in line with the notion that we can use colm transformations for new language features, before they are eventually moved into the main program.
* allow simple variable defs in colm bootstrap grammarAdrian Thurston2019-12-272-2/+32
| | | | | These are allowed, but ignored in bootstrap0 and bootstrap1. We can then use them in the rewriter to log changes we made.
* Created a common superclass for the export classesAdrian Thurston2019-12-276-65/+70
| | | | | | Every class representing Colm types has a program and tree pointer and some common functions. Moving this out allows us to pass the common base to the repeat iterator and eliminate the first argument to the iterator.
* disable julia tests until we can sort out changesAdrian Thurston2019-12-261-0/+6
| | | | | | The Julia language has changed enough to break our tests. Disable them for now. refs #91
* some improvements to the --with-colm build optionAdrian Thurston2019-12-262-5/+21
| | | | | This flag is not for production building. Bootstrapped build should always be used.
* left/right-independent iterator for repeats in top-down loadsAdrian Thurston2019-12-268-158/+259
| | | | | | | | | | Added an iterator for repeats that is independent of left/right recursion. Using it in colm load and tests. Allows us to remove the special case for repeat/list types in the export. The new iterator is implemented as a non-recursive generic tree iterator. refs #90
* run the build-test action on our own git action runnerAdrian Thurston2019-12-221-1/+1
|
* use left-recursing in the colm grammarAdrian Thurston2019-12-2213-70/+142
| | | | | | Also moved the implementation to C++ because for the time being we need to generate an appropriate iterator in the export interface. Need a genereric repeat iterator to avoid this situation.