Releases: ceylon/ceylon.ast
ceylon.ast 1.3.3
ceylon.ast 1.3.3
Changes from the previous version (1.3.2):
- A
CaseClauseand aCaseExpressionhave an additional boolean modifier,elseCase,
indicating a non-disjoint case (syntaxelse caseinstead of justcase). See #137. - A
ModuleSpecifierhas an additionalClassifier(a new alias forStringLiteral). See #135. - A
ModuleBodyhas an additional listconstantDefinitionsofValueDefinitions, and aModuleImport’sversionmay also be aBaseExpression. See #136.
Unfortunately, one minor language change could not be adopted in this version: Support for of package.foo is not added in this release. See #134.
The .car files for this release have been made reproducible using a fork of Debian’s strip-nondeterminism program. The following script, on a fresh Debian Jessie GNU/Linux system, should produce the exact same binary:
#!/bin/bash
languageVersion=1.3.3
languageRelease=0
projectVersion=1.3.3
repoUser=ceylon
repoName=ceylon.ast
modules=(ceylon.ast.{core,create,redhat,samples})
repo=https://modules.ceylon-lang.org/repo/1
timestamp=1511111111
# install dependencies
apt install --yes --allow-unauthenticated \
git \
default-jre \
wget \
curl \
ant \
zip \
unzip \
libarchive-zip-perl \
python3 \
nodejs
# install Ceylon
cd /opt
wget https://downloads.ceylon-lang.org/cli/ceylon-${languageVersion}_${languageVersion}-${languageRelease}_all.deb
dpkg -i ceylon-${languageVersion}_${languageVersion}-${languageRelease}_all.deb
# build project
git clone https://github.com/$repoUser/$repoName
cd $repoName
git checkout $projectVersion
sed -i "/dist.root.dir=/ s =.*$ =/usr/share/ceylon/$languageVersion " build.properties
ant compile
cd ..
# strip nondeterminism
git clone https://github.com/lucaswerkmeister/strip-nondeterminism
cd strip-nondeterminism
for module in "${modules[@]}"; do
car="../$repoName/modules/${module//\.//}/$projectVersion/$module-$projectVersion.car"
perl -I lib -- bin/strip-nondeterminism -t car -T $timestamp "$car"
echo -n $(sha1sum "$car" | cut -f1 -d' ') > "$car".sha1
done
cd ..
# compare checksums
for module in "${modules[@]}"; do
echo
echo "$module"
cat "$repoName/modules/${module//\.//}/$projectVersion/$module-$projectVersion.car.sha1"; echo
curl "$repo/${module//\.//}/$projectVersion/$module-$projectVersion.car.sha1"; echo
done
exit 0ceylon.ast 1.3.2
ceylon.ast 1.3.2
Changes from the previous version (1.3.1):
- Module descriptors have received an update. A new node type,
ModuleSpecifier, has been added, representing the specification grammar rule of the same name. AModuleDescriptorand aModuleImportcan each have one (replacing aModuleImport’srepositoryTypemember). TheRepositoryTypehas been renamed to justRepositoryto match the specification (which did not exist whenRepositoryTypewas added), and aliasesArtifact,ModuleNameandModulehave been added. See #128, #129 and #133. Assertionnow has aStringLiteral|StringTemplate? messageinstead ofAnnotations annotations, defaulting tonull. See #131.- An incorrect example in the
MemberMetadocumentation has been removed. See #130.
The .car files for this release have been made reproducible using a fork of Debian’s strip-nondeterminism program. The following script, on a fresh Debian Jessie GNU/Linux system, should produce the exact same binary:
#!/bin/bash
languageVersion=1.3.2
languageRelease=0
projectVersion=1.3.2
repoUser=ceylon
repoName=ceylon.ast
modules=(ceylon.ast.{core,create,redhat,samples})
repo=https://modules.ceylon-lang.org/repo/1
timestamp=1490370000
# install dependencies
apt install --yes --allow-unauthenticated \
git \
default-jre \
wget \
curl \
ant \
zip \
unzip \
libarchive-zip-perl \
python3 \
nodejs
# install Ceylon
cd /opt
wget https://downloads.ceylon-lang.org/cli/ceylon-${languageVersion}_${languageVersion}-${languageRelease}_all.deb
dpkg -i ceylon-${languageVersion}_${languageVersion}-${languageRelease}_all.deb
# build project
git clone https://github.com/$repoUser/$repoName
cd $repoName
git checkout $projectVersion
sed -i "/dist.root.dir=/ s =.*$ =/usr/share/ceylon/$languageVersion " build.properties
ant compile
cd ..
# strip nondeterminism
git clone https://github.com/lucaswerkmeister/strip-nondeterminism
cd strip-nondeterminism
for module in "${modules[@]}"; do
car="../$repoName/modules/${module//\.//}/$projectVersion/$module-$projectVersion.car"
perl -I lib -- bin/strip-nondeterminism -t car -T $timestamp "$car"
echo -n $(sha1sum "$car" | cut -f1 -d' ') > "$car".sha1
done
cd ..
# compare checksums
for module in "${modules[@]}"; do
echo
echo "$module"
cat "$repoName/modules/${module//\.//}/$projectVersion/$module-$projectVersion.car.sha1"; echo
curl "$repo/${module//\.//}/$projectVersion/$module-$projectVersion.car.sha1"; echo
done
exit 0ceylon.ast 1.3.1
ceylon.ast 1.3.1
Changes from the previous version (1.3.0):
ceylon.ast’s goal has shifted:
ceylon.astnow aims to support all programs accepted by the typechecker,
including ones that are not covered by the specification.
See #123.- Imports no longer distinguish by case:
ImportAliasandImportElementare now concrete classes,
their former-Type-and-FunctionValue-subclasses
have been merged into the superclasses and removed.
See #122. - Tuple literal cases are now supported:
AMatchCase’sexpressionsmay now containTuples.
See #125. - Nested imports are now supported:
Bodynow has a memberImport[] imports
analogous to the one inAnyCompilationUnit.
In the subclass constructors, it defaults to[].
See #126. - Assignment operations can now have any
Expression
on the right-hand side, not justAssigningExpressions.
This has always been supported by the typechecker,
butceylon.astdid not previously support it
due to a misunderstanding of the specification.
See #121.
Note that on the JS backend, this release is afflicted by eclipse-archived/ceylon#6767; certain uses of ceylon.ast on the JS backend may be impossible.
The .car files for this release have been made reproducible using a fork of Debian’s strip-nondeterminism program. The following script, on a fresh Debian Jessie GNU/Linux system, should produce the exact same binary:
#!/bin/bash
version=1.3.1
project=ceylon.ast
modules=(ceylon.ast.{core,create,redhat,samples})
repo=https://modules.ceylon-lang.org/repo/1
timestamp=1480180000
# install dependencies
apt install --yes --allow-unauthenticated \
git \
default-jre \
wget \
curl \
ant \
zip \
unzip \
libarchive-zip-perl \
python3 \
nodejs
# install Ceylon
cd /opt
wget https://downloads.ceylon-lang.org/cli/ceylon-1.3.1_1.3.1-1_all.deb
dpkg -i ceylon-1.3.1_1.3.1-1_all.deb
# build project
git clone https://github.com/ceylon/$project
cd $project
git checkout $version
sed -i 's ../ceylon/dist/dist /usr/share/ceylon/1.3.1/ ' build.properties
ant compile
cd ..
# strip nondeterminism
git clone https://github.com/lucaswerkmeister/strip-nondeterminism
cd strip-nondeterminism
for module in "${modules[@]}"; do
car="../$project/modules/${module//\.//}/$version/$module-$version.car"
perl -I lib -- bin/strip-nondeterminism -t car -T $timestamp "$car"
echo -n $(sha1sum "$car" | cut -f1 -d' ') > "$car".sha1
done
cd ..
# compare checksums
for module in "${modules[@]}"; do
echo
echo "$module"
cat "$project/modules/${module//\.//}/$version/$module-$version.car.sha1"; echo
curl "$repo/${module//\.//}/$version/$module-$version.car.sha1"; echo
done
exit 0On other systems, adjust the first two command sections to use the correct package manager, and potentially the sed build.properties line to point to the correct Ceylon distribution directory.
(Note that the .car files depend slightly on the Java version; building under Java 8 instead of 7 is known to result in differently ordered MANIFEST.MF entries.)
ceylon.ast 1.3.0
ceylon.ast 1.3.0
Changes from the previous version (1.2.2):
ceylon.ast.redhat’scompileXfunctions have been renamed toparseXto better reflect their actual behavior. See #101 and b8f3959.- Support for repository types (aka namespaces) has been added.
ModuleImportgained a new optional parameterrepositoryTypeof typeRepositoryType?(a new alias forLIdentifier). See 4aa9051. - An
internalconstructor forLIdentifierandUIdentifierhas been added, which accepts dollar signs ($) in the name, to be used for internal variables generated by the compiler. A new field,valid, has been added toIdentifierto distinguish between valid and invalid identifiers. See #119. - The type of
KeySubscript.keyhas been widened fromAddingExpressiontoExpression. OnlySpanOperationandMeasureOperationare not permitted as children. See #118. - The type of
ExtensionOrConstruction.qualifierhas been widened fromBaseType|PackageQualifier|Super?toSimpleType|PackageQualifier|Super?, and the type ofExtension.qualifierhas been widened fromPackageQualifier|Super?toPackageQualifier|Super|SimpleType?. See #117. ImportElementsmay now be empty, that is, contain neither regular elements nor a wildcard. See #120.- The
Identifierconversion from RedHat AST to ceylon.ast did not accept identifiers with no token. As the typechecker sometimes adds such identifiers to the AST (desugaring), they are now supported. See #114, #115. - New build targets
test-tap,test-jvm-tapandtest-js-tapcan be used to obtain Test Anything Protocol reports for the tests (written to filestest-jvm.tapandtest-js.tap). - The RedHat AST gained a new node type
ParExpressionfor grouped expressions (instead of just anExpressionwith start and end token), soceylon.ast.redhatlearned to convert to/from this new type. See eclipse-archived/ceylon#6247, 593d167. - The size of the
ceylon.ast.redhatCAR file has been drastically reduced. See a2fd9d8.
The .car files for this release have been made reproducible using a fork of Debian’s strip-nondeterminism program. The following script, on a fresh Debian GNU/Linux system, should produce the exact same binary:
#!/bin/bash
version=1.3.0
project=ceylon.ast
modules=(ceylon.ast.{core,create,redhat,samples})
repo=https://modules.ceylon-lang.org/repo/1
timestamp=1474200000
# install dependencies
apt install --yes --allow-unauthenticated \
git \
default-jre \
wget \
curl \
ant \
zip \
unzip \
libarchive-zip-perl \
python3 \
nodejs
# install Ceylon
cd /opt
wget https://downloads.ceylon-lang.org/cli/ceylon-1.3.0_1.3.0_all.deb
dpkg -i ceylon-1.3.0_1.3.0_all.deb
# build project
git clone https://github.com/ceylon/$project
cd $project
git checkout $version
sed -i 's ../ceylon/dist/dist /usr/share/ceylon/1.3.0/ ' build.properties
ant compile
cd ..
# strip nondeterminism
git clone https://github.com/lucaswerkmeister/strip-nondeterminism
cd strip-nondeterminism
for module in "${modules[@]}"; do
car="../$project/modules/${module//\.//}/$version/$module-$version.car"
perl -I lib -- bin/strip-nondeterminism -t car -T $timestamp "$car"
echo -n $(sha1sum "$car" | cut -f1 -d' ') > "$car".sha1
done
cd ..
# compare checksums
for module in "${modules[@]}"; do
echo
echo "$module"
cat "$project/modules/${module//\.//}/$version/$module-$version.car.sha1"; echo
curl "$repo/${module//\.//}/$version/$module-$version.car.sha1"; echo
done
exit 0On other systems, adjust the first two command sections to use the correct package manager,
and potentially the sed build.properties line to point to the correct Ceylon distribution directory.
ceylon.ast 1.2.2
ceylon.ast 1.2.2
Changes from the previous version (1.2.1):
- Several changes have been made to
Editorin an effort to improve performance:- The
editmethods for abstract node classes and precedence aliases are no longerdefault. They are usually not called anyways, sinceEditorsatisfiesImmediateNarrowingTransformer, so if you overwrote them for whatever reason, this was almost certainly a bug. See #112. - The
editmethods for leaf nodes (that is, nodes without child nodes) have been changed to skip thecopycall and directly return the edited node, since for these nodescopyis a no-op anyways. See #111. - The method
editNodeis added to provide a heuristic whether a given node will be changed by the editor or not. IfeditNodereturnsfalse, the default implementations of theeditmethods for non-leaf nodes will directly return the edited node without callingcopyor editing child nodes. By default,editNodealways returnstrue, so the behavior is the same as before. But editors that seek to improve performance can overwrite it with some heuristic to avoid unnecessary edits in some cases. See #111.
- The
- The
ClassDecconversion from RedHat AST to ceylon.ast did not accept lowercase identifiers, which are valid in declarations that refer to the class of an object. See #113.
The .car files for this release have been made reproducible using a fork of Debian’s strip-nondeterminism program.
The following script, on a fresh Arch Linux system, should produce the exact same binary:
#!/bin/bash
version=1.2.2
project=ceylon.ast
modules=(ceylon.ast.{core,create,redhat,samples})
repo=https://modules.ceylon-lang.org/repo/1
timestamp=1460140000
# install dependencies
pacman -S --noconfirm \
git \
jdk8-openjdk \
wget \
curl \
apache-ant \
zip \
unzip \
perl-archive-zip \
python
# install Ceylon
cd /opt
wget https://downloads.ceylon-lang.org/cli/ceylon-$version.zip
unzip ceylon-$version.zip
export PATH="$PATH:/opt/ceylon-$version/bin"
# build project
git clone https://github.com/ceylon/$project
cd $project
git checkout $version
sed -i "s|../ceylon/dist/dist|/opt/ceylon-$version|" build.properties
ant compile
cd ..
# strip nondeterminism
git clone https://github.com/lucaswerkmeister/strip-nondeterminism
cd strip-nondeterminism/lib
for module in "${modules[@]}"; do
car="../../$project/modules/${module//\.//}/$version/$module-$version.car"
../bin/strip-nondeterminism -t car -T $timestamp "$car"
echo -n $(sha1sum "$car" | cut -f1 -d' ') > "$car".sha1
done
# compare checksums
for module in "${modules[@]}"; do
echo
echo "$module"
cat "../../$project/modules/${module//\.//}/$version/$module-$version.car.sha1"; echo
curl "$repo/${module//\.//}/$version/$module-$version.car.sha1"; echo
done(This is almost certainly not specific to Arch Linux, but that’s where it was tested. On other systems, adjust the pacman -S line to use the correct package manager, or remove it entirely if the packages are already installed.)
ceylon.ast 1.2.1
Changes from the previous version (1.2.0):
-
Support for value constructors, forgotten in 1.2.0, was added. The node type previously called
ConstructorDefinitionwas renamed toCallableConstructorDefinition(and itsceylon.ast.createfunction accordingly), and a new typeValueConstructorDefinition(including aceylon.ast.createfunction), as well as a new supertypeConstructorDefinition, were added. See #102. -
When adding conditional, let, and object expressions for 1.2.0, I did not realize that they could also appear within operations:
The expression ... is parsed with precedence just higher than the
||operator, and just lower than thethenandelseoperators, that is, between the layers 3 and 4 defined in §6.8.1 Operator precedence.To rectify this, a new precedence alias
StructureExpressionhas been inserted betweenThenElseExpressionandDisjoiningExpression. This also required thatBinaryOperationandOperationwere slightly relaxed, now allowing anyExpressionas children rather than justValueExpressions. See #104. -
switchcases can contain certain expressions that, grammatically, are qualified expressions:switch (thing) case (package.someObject) {} case (SomeClass.valueConstructor) {}
This was not previously supported in
ceylon.ast; to fix this, aMatchCasemay now also containQualifiedExpressions. See #103. -
There are now two sets of methods to access a node’s additional information:
get,put, andremoveoffer more type information, whilegetObject,set, anddeletecan be slightly faster. (setalready existed;getObjectanddeleteare new.) For those that use additional information very extensively and absolutely need it to perform the best possible, there is also a new, untyped fielddatathat can be directly set or gotten. Don’t use it. See #108. -
Visitorno longer satisfiesWideningTransformer<Anything>; instead, it’s an independent, unparameterized interface. This was done for performance reasons. This should have no effect on your code, unless you actually utilized this (mostly theoretical) connection. See #109. -
Various bugfixes and minor changes. See #105, #106, #107, #110.
The .car files for this release have been made reproducible using a fork of Debian’s strip-nondeterminism program. The following script, on a fresh Arch Linux system, should produce the exact same binary:
#!/bin/bash
# install dependencies
pacman -S --noconfirm \
git \
jdk8-openjdk \
wget \
curl \
apache-ant \
zip \
unzip \
perl-archive-zip \
python
# install Ceylon
cd /opt
wget https://downloads.ceylon-lang.org/cli/ceylon-1.2.1.zip
unzip ceylon-1.2.1.zip
export PATH="$PATH:/opt/ceylon-1.2.1/bin"
# build ceylon.ast
git clone https://github.com/ceylon/ceylon.ast
cd ceylon.ast
git checkout 1.2.1
sed -i 's|../ceylon/dist/dist|/opt/ceylon-1.2.1|' build.properties
ant compile
cd ..
modules=(ceylon.ast.{core,redhat,create,samples})
version=1.2.1
# strip nondeterminism
git clone https://github.com/lucaswerkmeister/strip-nondeterminism
cd strip-nondeterminism/lib
for module in "${modules[@]}"; do
car="../../ceylon.ast/modules/${module//\.//}/$version/$module-$version.car"
../bin/strip-nondeterminism -t car -T 1455380000 "$car"
echo -n $(sha1sum "$car" | cut -f1 -d' ') > "$car".sha1
done
# compare checksums
for module in "${modules[@]}"; do
echo
echo "$module"
cat "../../ceylon.ast/modules/${module//\.//}/$version/$module-$version.car.sha1"; echo
curl "https://modules.ceylon-lang.org/repo/1/${module//\.//}/$version/$module-$version.car.sha1"; echo
doneceylon.ast 1.2.0
Changes from the previous version (1.1.0):
- Support for new language features
- To support constructors,
ConstructorDefinitionandConstructorDecwere added.ClassInstantiationwas replaced byExtensionOrConstructionand its two subclasses,ExtensionandConstruction.ClassDefinitionwas updated to make theparametersoptional.
See #71 and ceylon/ceylon-spec#796. LetExpression,ObjectExpression,ConditionalExpression,IfElseExpression,CaseExpressionandSwitchCaseElseExpressionwere added.
See #65, #66, #67, and #68.- To support destructuring,
VariadicVariable,Pattern,VariablePattern,TuplePattern,EntryPattern,SpecifiedPattern,PatternListandDestructurewere added.KeyValueIteratorwas removed; instead, aForIteratornow has apatternand aniteratedexpression.ExistsConditionandNonemptyConditionnow take aSpecifiedPatterninstead of aSpecifiedVariable, and the child member was renamed fromvariabletotested.
See #75 and ceylon/ceylon-spec#520. - Qualifiers of meta and declaration expressions, as well as of types, were updated.
PackageQualifierwas added. An optionalqualifierwas added toBaseType. Instead of a nonempty list of eitherUIdentifiers orLIdentifiers, aDecQualifiernow has a possibly-empty list ofIdentifiers, as well as an optionalPackageQualifier. Since aDecQualifiermay now be empty, it is no longer optional as child of allDectypes.MetaQualifierwas removed, andMemberMetas are instead qualified by anyPrimaryType. An optionalPackageQualifierqualifierwas added toBaseMeta.
See #80, ceylon/ceylon-spec#1243 and ceylon/ceylon-spec#1245. - The
identifierofModuleDec,PackageDec, andTypeDecand its subclasses (ClassDec,InterfaceDec) is now optional to support the new abbreviated syntax for references:module,classetc.
See ceylon/ceylon-spec#1115. - A
SequentialTypenow has an optionallength(anIntegerLiteral) to support the new length-based abbreviation for tuple types (which was already in Ceylon 1.1, but only specified in 1.2).
See #52 and ceylon/ceylon-spec#1041. - A
SwitchClausenow has aswitchedinstead of anexpression, which may be aSpecifiedVariableas well as anExpression. To avoid ambiguity, ifswitchedis anAssignOperation, thetargetmay not be aBaseExpression.
See #70 and ceylon/ceylon-spec#1119. SpreadType, a type prefixed by an asterisk, was added. ACallableType’sargumentTypesmay now be aSpreadTypeas well as aTypeList.
See #72 and ceylon/ceylon-spec#1121.- To support negated
existsandnonemptyconditions, a flagnegatedwas added toExistsOrNonemptyCondition,ExistsConditionandNonemptyCondition.
See #76. - An optional
thisqualifierwas added toValueSpecificationandLazySpecification.
See #78 and ceylon/ceylon-spec#1122. StringTemplatewas changed to contain anyExpressions, not justValueExpressions.
See #83 and ceylon/ceylon-spec#1270.TypeArgumentsmay now be empty.
See ceylon/ceylon-spec#791.IterableType’svariadicTypeis no longer optional. This was actually incorrect before, since ceylon/ceylon-spec#1005 was never added.
See #84.CallableParameterandFunctionDeclaration’stypewere changed to allow the same types asFunctionDefinition:Type|VoidModifier|FunctionModifier|DynamicModifier.
See 0124da5 and ceylon/ceylon-spec#1303.InterfaceBodywas changed to allow specification statements in addition to declarations.
See #91 and ceylon/ceylon-spec#1389.
- To support constructors,
- All
xToCeylonandcompileXfunctions now take an optional second parameter,update. This is a function that is called once for every RedHat AST node and ceylon.ast node converted. It can be used to attach information from the RedHat AST node to the ceylon.ast node that was created from that RedHat AST node. The default value for this parameter isnoop; the functionattachOriginalNodeis available as an alternative option, which attaches the original node using theoriginalNodeKey.
See #87. FloatLiteral.floatandIntegerLiteral.integerwere removed. ceylon.ast now doesn’t evaluate any literals for you.
See #97 and #98.ExpressionIshwas removed.
See #73.- The default instances of
SelfReferencetypes -thisInstance,superInstance,outerInstance, andpackageInstance- have been removed. If you used them, that was a mistake, since the assumption that they are indistinguishable was violated even in the 1.1.0 release by the introduction of extra info on nodes (see #17).
See ffc0af3. - The
annotationsparameter ofVariadicParameterandCallablePArameternow defaults to emptyAnnotations().
See 1249322. - The order of child nodes in
childrendid not always match their order in source code. This was fixed.
See #77. - The
equalsmethod of all node types was rewritten to be smaller and (hopefully) more efficient.
See #79. - The type of certain
childrenmembers was changed to be more precise, which had previously been prevented by several compiler bugs.
See 5661c23 and 446bc06. - JS modules are now also published to Herd (forgotten last release).
1.1.0
Initial release of ceylon.ast. Includes four modules:
ceylon.ast.core: Pure Ceylon definition of a Ceylon Abstract Syntax Tree.
Includes interfaces to analyze (Visitor), modify (Editor) and operate on
(Transformer) ASTs.ceylon.ast.redhat: Conversion betweenceylon.astand RedHat AST nodes.
Required for interoperation with the compiler or the formatter.ceylon.ast.create: Utility functions to simplify the creation of various
types of nodes.ceylon.ast.samples: Demonstrations of various aspects ofceylon.ast.
Google Summer of Code 2014 submission state
This is the state of ceylon.ast as of 2014-08-18 19:00 UTC, the Google Summer of Code 2014 deadline.
The following syntactic elements of Ceylon have not yet been added:
- interfaces
- some types of named arguments
- switch/case
- try/catch/finally
- comprehensions
- dynamic blocks
- element expressions (
x[i],s[x..y]) - different member operators:
.,?.,*. - most decs (detyped metamodel literals)
- interface and type aliases (class aliases might change too)
- operator-style expressions
For all other syntactic elements of Ceylon, the following features are
available:
- An immutable Ceylon class representing the syntactic element (node), feasible for creation using named arguments (a highly readable syntax)
- Means to attach any amount of arbitrary information to any node, in a typesafe way (for example, a parser might attach tokens, a compiler may attach model information, etc.)
- A mechanism to operate on and transform nodes (
Transformer), including- a way to implement any operations on nodes (
Visitor) (transformation into nothing) - a scaffolding to edit and change nodes (
Editor) (transformation into a copy of the same type)
- a way to implement any operations on nodes (
- A transformation of nodes into their textual representation: a Ceylon expression that, when evaluated, yields an exact copy of the node (
CeylonExpressionVisitor,Node.string) - Transformation of nodes to and from the RedHat compiler’s AST (
RedHatTransformer) - Compilation of nodes from a code string, using the RedHat compiler’s parser and the aforementioned transformation
The core functionality resides in the ceylon.ast.core module, which is implemented in pure Ceylon and backend-independent. The RedHat AST conversion and compilation resides in the ceylon.ast.redhat module and naturally depends on the RedHat compiler; therefore, it is, like the RedHat compiler itself, only available for the Java backend.
The ceylon.ast.samples module contains sample ASTs for illustratory, educational or testing purposes. Currently, the only sample available is the ceylon.ast.samples.helloworld package, containing ASTs for a module descriptor, a package descriptor and a regular compilation unit which together form a complete "Hello, World!" program.