Skip to content

apollo-compiler@0.9.2

Compare
Choose a tag to compare
@goto-bus-stop goto-bus-stop released this 23 May 11:32
· 427 commits to main since this release
aa41b30

Features

  • add as_$type() methods to hir::Value, by goto-bus-stop in pull/564

    These methods simplify casting the hir::Value enum to single Rust types.
    Added methods:

    • hir::Value::as_i32() -> Option<i32>
    • hir::Value::as_f64() -> Option<f64>
    • hir::Value::as_str() -> Option<&str>
    • hir::Value::as_bool() -> Option<bool>
    • hir::Value::as_list() -> Option<&Vec<Value>>
    • hir::Value::as_object() -> Option<&Vec<(Name, Value)>>
    • hir::Value::as_variable() -> Option<&Variable>

Fixes

  • non-nullable variables should be accepted for nullable args, by lrlna in pull/565

    Fixes several null-related issues from 0.9.0.

  • add an UndefinedVariable diagnostic, by goto-bus-stop in pull/563

    Previously undefined variables were reported with an UndefinedDefinition diagnostic.
    Splitting it up lets us provide a better error message for missing variables.