summaryrefslogtreecommitdiff
path: root/dhall/src (unfollow)
Commit message (Collapse)AuthorFilesLines
2021-04-10add type substitutions to serde_dhallstuebinm2-0/+18
this adds subsititutions, which work similar to the `Dhall.substitutions` mechanism of the Haskell dhall package, and which can be used e.g. like this: ```rust serde_dhall.from_str(...) .substitute_names(hashmap!["Newtype" => static_type]) .parse::<SimpleType>()? ``` The idea behind this is to make it easy to add programmer-defined types which may be used in configs for programs, without forcing the program's users to re-import the same type definitions each time (or the programmers to keep the dhall-based definitions in sync with their rust types, since these are now generated automatically). Caveats so far: - makes some of the code ugly (dhall internals are now used in serde_dhall/src/lib.rs, for example) - haven't tested error messages so far - some unecessary copying of strings and static type values
2021-04-03release: dhall version 0.10.1Nadrieril1-1/+1
2021-04-03clippy: ignore unknown lintsNadrieril1-1/+2
2021-04-03clippy: ignore upper_case_acronymsNadrieril1-2/+3
2021-04-03fix: fix formattingNadrieril1-1/+1
2021-04-03Ignore clippy's needless question mark lint for the ast visitor macros.Ceri Storey1-1/+2
2021-04-03Avoid ambiguity from use of Itertools::intersperse.Ceri Storey2-6/+5
2021-03-27Replace a bunch of Err(…)? and format!("constant") calls.Ceri Storey2-2/+2
2021-03-09chore: fix clippy warningsNadrieril1-0/+1
2021-02-04release: dhall version 0.10.0Nadrieril1-1/+1
2021-01-22chore: fix clippy warningsNadrieril2-8/+6
2020-12-08tweak: factor a bitNadrieril1-24/+25
2020-12-08fix: fix import ordering issueNadrieril1-7/+7
2020-12-07Soothe clippyNadrieril1-0/+1
2020-12-07Resolve imports and alternatives outside of the ast traversalNadrieril6-130/+294
2020-12-07Defer name errors to typecheckingNadrieril4-5/+13
We aren't supposed to inspect anything before alternatives are chosen
2020-12-07Avoid storing an import before we checked its hashNadrieril2-23/+28
2020-12-07Unify `skip_resolve_expr` with normal resolutionNadrieril6-39/+74
2020-12-07Pass import results via the global contextNadrieril4-13/+19
2020-12-07Thread cx everywhere else imports are readNadrieril7-69/+68
2020-12-07Tag cx ids with the cx lifetimeNadrieril3-19/+31
To make sure we don't let ids escape and we don't mix scopes.
2020-12-07Thread cx through normalizationNadrieril15-347/+395
2020-12-07Thread cx through typecheckNadrieril8-28/+65
2020-12-07Improve ergonomics of `Ctxt`Nadrieril2-55/+55
2020-12-07Make global store of imports and import resultsNadrieril4-62/+200
2020-12-06An import location is not independent from the import modeNadrieril2-117/+107
2020-12-06Prepare `ImportLocation` for more fieldsNadrieril2-38/+82
2020-11-27If can return a typeBasile Henry1-2/+2
2020-11-20release: dhall version 0.9.0Nadrieril1-1/+1
2020-11-03Remove NirInternalNadrieril2-50/+23
2020-11-03Typecheck `with` using mutationNadrieril3-45/+25
2020-11-03Normalize `with` by mutation.Nadrieril4-57/+66
This is Cow-style mutation: we clone only what's shared and then mutate it. This it more legible and more efficient than the immutable version.
2020-11-03Try to keep ownership of `Nir`s when convenientNadrieril2-55/+52
The goal is that we might avoid cloning internals in the common case where a value is not shared
2020-11-02Handle record type properlyBasile Henry1-1/+1
2020-11-02Inline helper functionBasile Henry1-8/+4
2020-11-02Refactor following PR reviewBasile Henry2-29/+20
2020-11-01Handle partially abstract withBasile Henry1-8/+29
2020-11-01Implement normalization for With opBasile Henry1-2/+43
2020-11-01Implement type checking for With opBasile Henry2-31/+52
2020-11-01fix: clippyNadrieril2-21/+18
2020-11-01feat: add location to import error messagesNadrieril1-2/+10
This is crude but helpful. See #40
2020-11-01Ensure that the hash always gets checkedNadrieril2-19/+40
2020-11-01Typed and TypedHir are the sameNadrieril3-33/+26
2020-11-01Untangle caching codeNadrieril10-661/+155
2020-11-01Store file cache in ImportEnvNadrieril4-21/+22
2020-11-01Untangle ImportEnv::handle_importNadrieril2-29/+37
2020-11-01Allow `Text/replace ` to support an abstract haystackBasile Henry1-22/+28
2020-10-30Update annotate-snippets dependencyNadrieril1-12/+13
2020-10-30Roll our own Value for binary decodingNadrieril1-12/+162
2020-10-30Don't use serde_cbor::Value in binary encodingNadrieril1-40/+40