Commit Graph

18 Commits

Author SHA1 Message Date
Eduard Burtescu
7cece8725b syntax: fix fallout of merging ast::ViewItem into ast::Item. 2015-01-21 16:27:26 +02:00
Flavio Percoco
8b883ab268 Add syntax for negative implementations of traits
This commit introduces the syntax for negative implmenetations of traits
as shown below:

`impl !Trait for Type {}`

cc #13231
Part of RFC #3
2015-01-04 23:16:13 +01:00
Nick Cameron
e656081b70 Accept ?Sized as well as Sized?
Includes a bit of refactoring to store `?` unbounds as bounds with a modifier, rather than in their own world, in the AST at least.
2014-12-26 10:16:24 +13:00
Niko Matsakis
22f777ba2e Parse unsafe impl but don't do anything particularly interesting with the results. 2014-12-14 11:11:55 -05:00
Niko Matsakis
5686a91914 Parse unsafe trait but do not do anything with it beyond parsing and integrating into rustdoc etc. 2014-12-14 11:11:55 -05:00
Jorge Aparicio
0dac05dd62 libsyntax: use unboxed closures 2014-12-13 17:03:47 -05:00
Aaron Turon
b299c2b57d Fallout from stabilization 2014-11-25 17:41:54 -08:00
Alex Crichton
3dbd32854f rustc: Process #[cfg]/#[cfg_attr] on crates
This commit implements processing these two attributes at the crate level as
well as at the item level. When #[cfg] is applied at the crate level, then the
entire crate will be omitted if the cfg doesn't match. The #[cfg_attr] attribute
is processed as usual in that the attribute is included or not depending on
whether the cfg matches.

This was spurred on by motivations of #18585 where #[cfg_attr] annotations will
be applied at the crate-level.

cc #18585
2014-11-07 12:04:28 -08:00
Steven Fackler
9acce10fe7 Finish cfg syntax transition 2014-10-25 16:43:14 -07:00
bors
d670d76221 auto merge of #17963 : sfackler/rust/cfg-error, r=alexcrichton
All deprecation warnings have been converted to errors. This includes
the warning for multiple cfgs on one item. We'll leave that as an error
for some period of time to ensure that all uses are updated before the
behavior changes from "or" to "and".
2014-10-13 12:27:43 +00:00
Steven Fackler
aa3b1261b1 Continue cfg syntax transition
All deprecation warnings have been converted to errors. This includes
the warning for multiple cfgs on one item. We'll leave that as an error
for some period of time to ensure that all uses are updated before the
behavior changes from "or" to "and".
2014-10-12 11:40:19 -07:00
Jakub Wieczorek
403cd40e6a Remove virtual structs from the language 2014-10-11 19:42:26 +02:00
bors
ff2616e847 auto merge of #17630 : sfackler/rust/cfg-warnings, r=brson
Closes #17490
2014-10-01 09:22:15 +00:00
Steven Fackler
92013a849d Turn on cfg format warnings 2014-09-30 12:52:00 -07:00
Kevin Ballard
976438f78f Produce a better error for irrefutable if let patterns
Modify ast::ExprMatch to include a new value of type ast::MatchSource,
making it easy to tell whether the match was written literally or
produced via desugaring. This allows us to customize error messages
appropriately.
2014-09-30 18:54:02 +02:00
Steven Fackler
9519abecfb Convert cfg syntax to new system
This removes the ability to use `foo(bar)` style cfgs. Switch them to
`foo_bar` or `foo="bar"` instead.

[breaking-change]
2014-09-27 22:59:26 -07:00
Patrick Walton
78a841810e librustc: Implement associated types behind a feature gate.
The implementation essentially desugars during type collection and AST
type conversion time into the parameter scheme we have now. Only fully
qualified names--e.g. `<T as Foo>::Bar`--are supported.
2014-09-17 16:38:57 -07:00
Nick Cameron
520671f150 move most of front to libsyntax 2014-09-17 16:53:20 +12:00