Commit Graph

186 Commits

Author SHA1 Message Date
Huon Wilson 6c7291ece4 Update editor syntax files for isize/usize.
Yay, syntax highlighting.
2015-01-07 20:19:58 +11:00
Alex Crichton 7975fd9cee rollup merge of #20482: kmcallister/macro-reform
Conflicts:
	src/libflate/lib.rs
	src/libstd/lib.rs
	src/libstd/macros.rs
	src/libsyntax/feature_gate.rs
	src/libsyntax/parse/parser.rs
	src/libsyntax/show_span.rs
	src/test/auxiliary/macro_crate_test.rs
	src/test/compile-fail/lint-stability.rs
	src/test/run-pass/intrinsics-math.rs
	src/test/run-pass/tcp-connect-timeouts.rs
2015-01-05 19:01:17 -08:00
Keegan McAllister c9f0ff3813 Reserve the keyword 'macro' 2015-01-05 18:21:14 -08:00
Chase Southwood faf07b1365 Update reexports in vim syntax file 2015-01-05 12:21:47 -06:00
Chase Southwood c8fcbe7561 Fix vim syntax highlighting for derive 2015-01-02 15:06:13 -06:00
Brian Anderson e52efe262d rollup merge of #19804: kballard/vim-new-unicode-escapes 2014-12-15 06:45:36 -08:00
Brian Anderson 0b214bfee0 rollup merge of #19784: csouth3/vim-syntax-iter
Vim still incorrectly highlights just `ExactSize` as a valid trait name, but the trait has been renamed to `ExactSizeIterator`.
2014-12-15 06:45:35 -08:00
Niko Matsakis 0fefd835f2 Update emacs and vi modes. 2014-12-14 04:21:57 -05:00
Kevin Ballard d333a91009 vim: Support the new \u{1234} unicode escapes 2014-12-12 21:26:22 -08:00
Chase Southwood 0a015f287b Update vim syntax highlighting for ExactSizeIterator 2014-12-12 15:09:26 -06:00
Chris Morgan dc0416ebce Update the Vim syntax prelude. 2014-11-20 11:00:45 +11:00
Brendan Zabarauskas 2d8ca045d6 Rename IntoStr to IntoString
For consistancy with ToString
2014-11-16 12:41:55 +11:00
Brendan Zabarauskas de938b6ca1 Remove Signed trait and add SignedInt trait
The methods have been moved into Float and SignedInt
2014-11-13 03:46:03 +11:00
Brendan Zabarauskas 26196715e8 Deprecate Num, Unsigned and Primitive 2014-11-13 02:04:31 +11:00
Brendan Zabarauskas e51cc089da Move checked arithmetic operators into Int trait 2014-11-13 02:02:44 +11:00
Josh Stone e94912aa85 vim: move 'move' to rustStorage 2014-11-10 13:48:17 -08:00
bors 830c82dd74 auto merge of #18782 : netvl/rust/update-vim-syntax, r=alexcrichton
`as` (already for a long time) and `move` (which was only added recently, AFAIK) are not marked as keywords in Vim syntax file, so they are not highlighted as keywords in Rust sources. This PR fixes this.
2014-11-10 07:01:49 +00:00
Vladimir Matveev 3961eaec85 Added move keyword and renamed fail to panic 2014-11-09 21:10:08 +03:00
gamazeps 16c8cd931c Renamed Extendable to Extend
In order to upgrade, simply rename the Extendable trait to Extend in
your code

Part of #18424

[breaking-change]
2014-11-08 15:02:09 +01:00
Chris Morgan a118bd77ad Highlight 1..2 according to the current grammar. 2014-10-14 11:49:48 +11:00
Chris Morgan 81da141b7d Highlight extern crate "foo" as bar; properly. 2014-10-14 11:49:12 +11:00
Chris Morgan add8a85905 Vim: Stop highlighting foo in use foo; specially
This wasn’t really consistent with other things; the last section of the
import was not highlighted in any other case.

Also `use {foo, bar};` was having the foo and bar not highlighted, where
they would have been as separate statements.
2014-10-14 11:44:34 +11:00
John Gallagher 4d190b1235 Add abstract, final, and override to rust.vim keyword list 2014-10-07 22:18:36 -04:00
gamazeps e543878f0f Replaced some TODO by FIXME
closes #17478
2014-09-29 18:14:28 +02:00
bors dc65307e3b auto merge of #16547 : huonw/rust/new-kw, r=pcwalton 2014-08-17 14:56:08 +00:00
bors 6dca1426bc auto merge of #16535 : michaelsproul/rust/vim-traits, r=pcwalton
The vim syntax highlighting file had become out of sync with the real prelude.

Lots of Vector -> Slice renames have happened recently.
2014-08-17 06:26:09 +00:00
Huon Wilson d1c5db326f Add new keywords (particularly where & virtual) to editor modes. 2014-08-17 11:57:22 +10:00
Michael Sproul 1a5816a9aa vim: Update syntax file for Prelude changes.
Lots of Vector -> Slice renames.
2014-08-16 21:07:27 +10:00
Kevin Ballard ab65869c9d vim: Don't set foldmethod in the syntax file either
We shouldn't be setting any settings in the syntax file. Better to put
them in the ftplugin, where they won't be pulled in by :syn-include and
can be cleaned up when changing the filetype.
2014-08-15 16:41:07 -07:00
Alex Crichton 1f760d5d1a Rename Share to Sync
This leaves the `Share` trait at `std::kinds` via a `#[deprecated]` `pub use`
statement, but the `NoShare` struct is no longer part of `std::kinds::marker`
due to #12660 (the build cannot bootstrap otherwise).

All code referencing the `Share` trait should now reference the `Sync` trait,
and all code referencing the `NoShare` type should now reference the `NoSync`
type. The functionality and meaning of this trait have not changed, only the
naming.

Closes #16281
[breaking-change]
2014-08-07 08:54:38 -07:00
Brian Anderson 2d79bfa415 vim: Add MutableSeq 2014-07-23 13:20:16 -07:00
Chris Morgan 0a0c6da564 Fix :syn-include usage of Vim filetype.
Here’s what the Vim manual says in *:syn-include*:

    :sy[ntax] include [@{grouplist-name}] {file-name}

	All syntax items declared in the included file will have the
	"contained" flag added.  In addition, if a group list is
	specified, all top-level syntax items in the included file will
	be added to that list.

We had two rules for `rustModPath`, one `contained` and the other not.
The effect was that the second (now renamed to `rustModPathInUse`) was
being included in the group list, and thus that all identifiers were
being highlighted as `Include`, which is definitely not what we wanted.
2014-07-21 13:14:34 +10:00
Chris Morgan ca6ffac4e4 Highlight $(…)* and $foo in Vim. 2014-07-21 13:13:51 +10:00
bors 316719e625 auto merge of #15476 : kballard/rust/more_vim_tweaks, r=chris
Tweak the text editing settings (softtabstop, textwidth, etc).

Add some settings to turn on folding and colorcolumn.

Add the undo_ftplugin changes that my previous patch forgot.
2014-07-16 15:36:21 +00:00
Richo Healey 12c334a77b std: Rename the ToStr trait to ToString, and to_str to to_string.
[breaking-change]
2014-07-08 13:01:43 -07:00
Kevin Ballard c6492040b2 Define a new setting g:rust_fold
g:rust_fold allows folding to be enabled. This lets the user turn on
folding without having to define autocommands.
2014-07-07 22:18:27 -07:00
Patrick Walton 7e4e99123a librustc (RFC #34): Implement the new Index and IndexMut traits.
This will break code that used the old `Index` trait. Change this code
to use the new `Index` traits. For reference, here are their signatures:

    pub trait Index<Index,Result> {
        fn index<'a>(&'a self, index: &Index) -> &'a Result;
    }
    pub trait IndexMut<Index,Result> {
        fn index_mut<'a>(&'a mut self, index: &Index) -> &'a mut Result;
    }

Closes #6515.

[breaking-change]
2014-07-07 11:43:23 -07:00
Alexandre Gagnon d6c988a669 Vim syntax file types and traits cleanup 2014-07-01 00:52:51 -04:00
bors 7689213713 auto merge of #14952 : alexcrichton/rust/const-unsafe-pointers, r=brson
This does not yet change the compiler and libraries from `*T` to `*const T` as
it will require a snapshot to do so.

cc #7362

---

Note that the corresponding RFC, https://github.com/rust-lang/rfcs/pull/68, has not yet been accepted. It was [discussed at the last meeting](https://github.com/rust-lang/rust/wiki/Meeting-weekly-2014-06-10#rfc-pr-68-unsafe-pointers-rename-t-to-const-t) and decided to be accepted, however. I figured I'd get started on the preliminary work for the RFC that will be required regardless.
2014-06-24 04:16:53 +00:00
Piotr Jawniak 0b9e4fcaff Update few files after comparison traits renaming
There were still Total{Ord,Eq} in docs and src/etc
2014-06-22 09:31:39 +02:00
Chris Morgan b0dff7a191 Vim: highlight invalid characters in char literals. 2014-06-18 17:01:52 -07:00
Chris Morgan 31dfcf9dc1 Vim: highlight escapes for byte literals. 2014-06-18 17:01:52 -07:00
Alex Crichton 3324257833 rustc: Start accepting *const T
This does not yet change the compiler and libraries from `*T` to `*const T` as
it will require a snapshot to do so.

cc #7362
2014-06-16 16:58:17 -07:00
Richo Healey 553074506e core: rename strbuf::StrBuf to string::String
[breaking-change]
2014-05-24 21:48:10 -07:00
Kevin Ballard bf0c6d8166 vim: Handle box expressions specially
Attempt to highlight the placement expression in a `box (expr) foo`
expression. Also treat GC as a keyword within the placement expression.

This doesn't work correctly for arbitrary expressions. Notably, this
makes no attempt at balancing delimiters. I believe handling that will
require rewriting the syntax rules to add a region for every pair of
delimiters. That may be a desirable thing to do in the end, because we
can then rewrite our indent rules based on the syntax and get rid of
cindent(), but for the time being, we'll just live with the limitation.
2014-05-20 15:06:53 -07:00
Kevin Ballard 229338d6ac Update rust.vim for the latest prelude/keywords 2014-05-20 13:35:51 -07:00
Alex Crichton 948526134b etc: Add box as a keyword to editor configs
This keyword is about to be used much more often than it was a few weeks ago,
it's time to tell editors about the new keyword.
2014-05-06 10:49:35 -07:00
Richo Healey 3ec9f05534 vim: Add StrBuf as type to hilighting 2014-04-18 16:57:03 -07:00
Steven Fackler 6e69712030 Support new attribute syntax in vim syntax file 2014-03-30 12:53:44 -07:00
Flavio Percoco 2e6607a1dd Remove Freeze and add Share in vim's syntax 2014-03-28 17:57:04 +01:00