Mike Gerwitz

Activist for User Freedom

aboutsummaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* expand-sequence: Fix TeX escapingv2.18.2Mike Gerwitz2018-09-121-2/+2
| | | | * src/preproc/expand/expand-sequence.xsl: {\\=>\}.
* symbols: Remove last remnants of @keepMike Gerwitz2018-09-121-2/+1
| | | | | * src/symtable/symbols.xsl (preproc:symtable)[lv:param]: Remove @keep. * test/symtable/symbols.xspec: Remove @keep.
* Add src/ symlink to doc/Mike Gerwitz2018-09-121-1/+1
| | | | | | | | Most LaTeX distributions prohibit loading files from parent directories. This gets around that for PDF builds. * doc/src: Add symlink. * doc/tame.texi, src/symtrable.xsl: Use it.
* expand: Correct priority of constant suffix templatesv2.17.5Mike Gerwitz2018-09-101-3/+3
| | | | | * src/current/include/preproc/expand.xsl (preproc:expand)[c:const]: Adjust priorities.
* js compiler: Escape exception stringMike Gerwitz2018-09-071-1/+1
| | | | | * src/current/compiler/js.xsl (compile)[lv:classify]: Escape output for Error.
* preproc: Remove @override from eseq:is-expandable functionMike Gerwitz2018-07-131-2/+1
| | | | | | | | This was throwing a warning in non-ancient versions of Saxon. It does not need to be there, nor should it be, nor do I know why it was put there. * src/current/include/preproc/template.xsl (eseq:is-expandable): Remove @override.
* linker: Use sequences for stacks (instead of trees)Mike Gerwitz2018-07-131-49/+42
| | | | | | | | | | | | | | | | | | This has a significant performance impact: processing time is cut in about half and memory usage is reduced by more than 50%. For example, a package that previously took 30s and 2.1GiB of memory to link now takes 14s and less than 900MiB of memory. I had tried to perform this optimization a couple years ago but was thwarted (I think) by the classifier markers. The previous commit did away with those. I'm encouraged by the gains from the low-hanging fruit. * src/current/compiler/linker.xsl (l:process-empty, l:stack-empty): Convert from l:pstack and l:sym-stack (respectively) to empty preproc:sym sequences. (l:depgen-process-sym)[preproc:sym]: Append to sequence rather than outputting new l:sym-stack tree. Update all annotations and uses accordingly.
* linker: Remove classifier vs. calculation distinctionMike Gerwitz2018-07-132-127/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is something that I thought would be useful back in the day when TAME was in its infancy, but it is not important. Rather than having the linker spend time trying to figure out what symbols belong in the classifier---and rather than keeping that complexity around---this simplifies things by making the existing `classify' method simply perform _all_ calculations, and then yield only the classification portion of the result. This isn't a problem in practice because, if we only desire the use of a classifier, then we create a "supplier" that only uses classifications and has no other dependencies. The end result is, as far as we care, the same. * src/current/compiler/js.xsl (compiler:entry-rater)[lv:package]: Initialize `classes' rather than invoking classifier (compiler:entry-classifier)[lv:package]: Invoke all calculations and return only classes to provide equivalent behavior. (compiler:exit-classifier): Post-process classifications from calculation results, iterating through classmap. (compiler:classifier-yields-map)[lv:package]: Output all classifications that are not generated. This differs slightly from the original implementation in that it includes all non-generated classes rather than just classes that have a non-generated `@yields'; this distinction is important since `compiler:exit-classifier' is now using it to produce a classification result set that doesn't contain all the generated stuff (since it didn't before, and shouldn't now). * src/current/compiler/linker.xsl: Update copyright year. (l:resolv-deps)[preproc:sym[@l:mark-inclass]]: Remove template. (l:resolv-deps)[preproc:sym...@l:mark-inclass...]: Remove template. (l:depgen-sym): Set type of result to `element(preproc:sym)', since `l:mark-inclass' is no longer produced. [inclass, needs-class-mark]: Remove variables and all instances where they are used. (l:dep-aug)[inclass]: Remove param. Stop producing `@inclass' attribute. (l:link-classifier)[lv:package]: Do not process any dependencies. This can be removed entirely in the future since it now only produces static code, which we can perhaps combine with a different block. (l:link-rater)[lv:package]: Remove mention of `inclass' for dependencies; all dependencies will now be compiled into this block.
* [DEV-3251] factor escape check out to a function, and also fix a bug.Greg Torbenson2018-07-022-8/+17
|
* remove debug codeGreg Torbenson2018-06-293-127/+5
|
* add support for escape-param attrShelly Shaver2018-06-293-6/+159
|
* Don't break interpolated comparison attributes when fixing static comparisons.v2.17.2Greg Torbenson2018-06-271-4/+4
|
* [DEV-3245] fixed bug preventing second paramater in conditionalsTaylor Cordes2018-06-261-3/+4
|
* Revert "fixed bug preventing second parameter in conditionals"Taylor Cordes2018-06-251-4/+3
| | | | This reverts commit 80ed214e121d925741aa0f064b36c96726c57fe9.
* fixed bug preventing second parameter in conditionalsTaylor Cordes2018-06-251-3/+4
|
* map: Uppercase and hash transformersMike Gerwitz2018-05-293-2/+159
| | | | | | | | | | This includes a SHA256 implementation which is _not_ intended for secure cryptographic operations; see src/js/sha256.js header for more information. * src/current/compiler/js.xsl (compiler:static): Echo src/js/sha256.js. [map_method_uppercase, map_method_hash]: New functions. * src/current/link.xsl: Include dslc-base.xsl. * src/js/sha256.js: New file.
* map: Add transformation supportMike Gerwitz2018-05-291-17/+109
| | | | | | | | | | * src/current/compiler/map.xsl (lvmc:get-method-func, lvmc:value-ref, lvmc:transformation-wrap): New functions, partyl extracted from below. (lvmc:compile)[lvm:map//lvm:from]: Use `lvmc:value-ref'. [lvm:map//lvm:from/lvm:translate]: Add `[@key]' to match. [lvm:map//lvm:transform]: New match. Ignore node entirely. (lvmc:concat-compile): Propagate symtable to `lvmc:compile'.
* Add __path-root paramMike Gerwitz2018-05-292-1/+20
| | | | | | | | | * src/current/include/dslc-base.xsl (__path-root): New param. * src/current/src/com/lovullo/dslc/DslCompiler.java (DslCompiler)[compile]: Resolve TAME root path. [_transform]: Set it. DEV-3115
* Cut down on namespace exports for object filesMike Gerwitz2018-05-154-8/+7
| | | | This should cut down on the file sizes a bit.
* Modify valparse to recurse into the RHS.v2.16.0Greg Torbenson2018-05-091-6/+13
|
* Move {src/current/tools=>build-aux}/*Mike Gerwitz2018-05-048-982/+7
|
* map: Support @index on all lvm:fromMike Gerwitz2018-04-161-0/+5
| | | | | * src/current/compiler/map.xsl (lvmc:compile)[lvm:map//lvm:from[*]]: Output index if @index is set.
* map: Support `from' within `set'Mike Gerwitz2018-04-161-2/+10
| | | | | | This was just a matter of proxying `type'. * src/current/compiler/map.xsl (lvmc:compile): Proxy `type' param.
* map: Tunnel symtableMike Gerwitz2018-04-111-19/+20
| | | | | | Simplifies coming changes. * src/current/compiler/map.xsl: Tunnel all `symtable' params.
* c1map: Add lvm:whenv2.14.0Mike Gerwitz2018-04-062-2/+65
| | | | | This allows for conditional nodes where lvm:if is not appropriate or cannot be used.
* c1map: Prevent iteration on conditionalsMike Gerwitz2018-04-061-0/+5
| | | | This does not work at all.
* map: Provide useful warnings when missing import/@pathMike Gerwitz2018-04-051-1/+11
| | | | | | | | | | This is all really confusing because this doesn't use the same import specification as packages; maps got stuck in a partial transition. So, let's provide some helpful errors rather than silently failing. * src/current/compiler/map.xsl (preproc:symtable)[lvm:import]: Error if missing `@path'. Provide more information if `@package' was provided to help clarify.
* Add class, param, const, rate to param-value/@identifierv2.13.0Mike Gerwitz2018-04-021-1/+30
| | | | | | * src/current/include/preproc/template.xsl (preproc:gen-param-value-style)[lv:param-value[@identifier]]: Add support for class, param, const, rate styling.
* Mark generated symbols as localv2.12.1Mike Gerwitz2018-03-283-4/+36
| | | | | | | | | | | | | We need to cut down on symbol imports as much as possible; the whole system starts dragging if we are importing thousands of symbols into a single package. * src/current/include/preproc/symtable.xsl (preproc:symtable)[lv:rate,c:*]: Mark as local if `@preproc:generated`. * src/current/include/preproc/template.xsl (preproc:macros)[lv:inline-template]: Mark generated templates as such. * src/symtable/symbols.xsl (preproc:symtable)[lv:template]: Mark as local if `@preproc:generated'.
* symtable: Detect duplicate symbols in the same packageMike Gerwitz2018-03-281-1/+7
| | | | | | * src/symtable.xsl (symtable:find-duplicates): Update description. Find duplicates in same package. * test/symtable.xspec: Update test case accordingly.
* js compiler: Prevent octals in generated codeMike Gerwitz2018-03-282-4/+26
| | | | | | | * src/current/compiler/js.xsl (compiler:js-number): New function to remove leading zeroes. (compile)[lv:const]: Use it. * src/current/compiler/js-calc.xsl (compile-calc)[c:const]: Use it.
* c1map: Add lvm:if/@eqShelly Shaver2018-03-212-1/+11
|
* rate-each: Gentle @no2.12.0Mike Gerwitz2018-03-192-4/+13
| | | | | | | | * src/current/compiler/js.xsl (compile-class-condtion)[lv:rate]: Do not consider @no's in predicate generation when `@preproc:gentle-no' is set. * src/current/include/preproc/macros.xsl (preproc:macros)[lv:rate-each]: Set `@preproc:gentle-no' on generated `lv:rate', since the generator handles `@no' itself.
* linker, summary: Reduce runlog outputMike Gerwitz2018-03-192-21/+20
|
* preproc/template: Add param-sym-value/@ignore-missingMike Gerwitz2018-03-161-12/+15
| | | | | | * src/current/include/preproc/template.xsl (preproc:gen-param-value)[lv:param-sym-value]: Suppress warning for missing symbol and yield empty string if `@ignore-missing='true'`.
* depgen: Include enum constants as typedef dependenciesv2.10.3Mike Gerwitz2018-02-281-0/+5
| | | | | | | This ensures that they are compiled into the `consts' object. * src/current/include/depgen.xsl (preproc:depgen)[lv:typedef]: Include `lv:enum/lv:item/@name' as dependencies.
* standlone: Correct consts reference for worksheetv2.10.2Mike Gerwitz2018-02-261-1/+1
| | | | | | This was broken in 0c020b7. * src/current/standalone.xsl (/): {rater_results=>rater}.consts.
* symtable: Do not mark symbols with generated yields as generatedMike Gerwitz2018-02-261-7/+2
| | | | | | | | | | | | The problem with this implementation was that, any time a generator had an associated generated @yields (which is common), it wouldn't be included in the summary page. We can address this in the future. It's not necessarily that it was incorrect; it's just how the system made use of it. * src/current/include/preproc/symtable.xsl (preproc:symtable)[lv:rate]: Do not mark @preproc:yields-generated symbols as @preproc:generated.
* validtor: Remove unresolved extern warningMike Gerwitz2018-02-261-7/+3
| | | | | | | See diff comment. * src/current/compiler/validate.xsl (lvv:validate)[c:*[@name or @of]]: Remove unresolved extern warning.
* entry-form: Integrate YAML test case console output as HTMLMike Gerwitz2018-02-232-7/+91
|
* depgen: Ignore template bodiesv2.9.14Mike Gerwitz2018-02-231-3/+4
| | | | | | | | Templates can expand into unexpected places, so sometimes warnings are inappropriately issued. * src/current/include/depgen.xsl (preproc:depgen)[lv:template]: Ignore. [lv:template/lv:param]: Remove (now unnecessary with above).
* Revert "program map: Use expanded (preprocessed) program"v2.9.11Mike Gerwitz2018-02-221-2/+2
| | | | | | This map is used for more than the program.xml! This reverts commit c64e8363fd962b401e6603e2e69ae55b3b4d1b89.
* program map: Use expanded (preprocessed) programv2.9.10Mike Gerwitz2018-02-221-2/+2
| | | | | * src/current/compiler/map.xsl (lvmc:compile)[lvm:program-map]: Use `program.expanded', which is the preprocessed output.
* entry-form: Clear YAML filename after loadingMike Gerwitz2018-02-191-0/+7
| | | | | This way the test case can be re-loaded; otherwise it is not recognized as a change and does not trigger the event.
* Correct param initializationMike Gerwitz2018-02-191-11/+31
|
* progtest: Display reader errors in browserMike Gerwitz2018-02-191-1/+2
|
* Initial embedding of YAML test case runnerMike Gerwitz2018-02-194-0/+94
|
* Produce consts as part of rater objectMike Gerwitz2018-02-192-14/+28
|
* Properly re-order classification predicates of any dimensionv2.9.3Mike Gerwitz2018-02-191-17/+11
| | | | | | | | In order for the cmatch algorithm to work properly, predicates must be re-ordered on @dim descending. * src/current/compiler/js.xsl (compile)[lv:classify]: Order all different dimensions, not just scalars.
* preproc: Fix lv:any-only conversion broken from last commitv2.9.2Mike Gerwitz2018-02-191-1/+1
| | | | | | Gah. This system really needs tests.