Commit graph

511 commits

Author SHA1 Message Date
bors-servo
c193f0f3a2 Auto merge of #9643 - paulrouget:resolveSymlink, r=larsbergstrom
Follow executable symlink to resolve resources directory

We need this if we ever want to be able to install Servo, for example: https://github.com/paulrouget/homebrew-servo

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9643)
<!-- Reviewable:end -->
2016-02-17 03:39:28 +05:30
bors-servo
7aedb9c7cd Auto merge of #9600 - danlrobertson:opts_parser_err, r=ecoal95
Add informative error messages when parsing command line options returns an error

The background behind why I'm submitting this PR is slightly embarrassing. After running `./mach` with some servo options I got the following stack backtrace.

```
thread '<main>' panicked at 'called `Result::unwrap()` on an `Err` value: ParseIntError { kind: InvalidDigit }', ../src/libcore/result.rs:746
stack backtrace:
   1:     0x56459001b0b0 - sys::backtrace::tracing:👿:write::hb120982054a416e35nu
   2:     0x56459001e02b - panicking::default_handler::_$u7b$$u7b$closure$u7d$$u7d$::closure.42840
   3:     0x56459001dc96 - panicking::default_handler::h7ae2e4523ef4c187IFy
   4:     0x56459000760c - sys_common::unwind::begin_unwind_inner::h5fb19481d14902dbDgt
   5:     0x564590007cf8 - sys_common::unwind::begin_unwind_fmt::hd62d57279546b0f2Jft
   6:     0x56459001a701 - rust_begin_unwind
   7:     0x56459004c01f - panicking::panic_fmt::h27f7225e08792f40qYL
   8:     0x56458f393901 - result::unwrap_failed::h18215968003310890981
                        at ../src/libcore/macros.rs:29
   9:     0x56458f3937b9 - result::Result<T, E>::unwrap::h10319050269194353824
                        at ../src/libcore/result.rs:687
  10:     0x56458f383701 - opts::from_cmdline_args::h8ea8d8c87dc6ee726lg
                        at /home/drobertson/git/servo/components/util/opts.rs:599
  11:     0x56458d1f8cdf - main::h8517eb49d15e90fbNaa
                        at /home/drobertson/git/servo/components/servo/main.rs:53
  12:     0x56459001d8f4 - sys_common::unwind::try::try_fn::h9076850075504893162
  13:     0x56459001a68b - __rust_try
  14:     0x56459001d36e - rt::lang_start::h58a22f304b0c1e19Oxy
  15:     0x56458d2f4aa9 - main
  16:     0x7f370496360f - __libc_start_main
  17:     0x56458d1c04a8 - _start
  18:                0x0 - <unknown>
Servo exited with return value 101
```

I immediately opened up `gdb` and got to work only to realize that the error was due to a typo in an option that had been `unwrap`ed at [components/util/opts.rs:599](https://github.com/servo/servo/blob/master/components/util/opts.rs#L599). Perhaps some more informative error messages will help prevent some future face-palm moments like mine 😄

I couldn't think of a good way to add tests for this. Please let me know if I missed something. Comments and critiques are welcome!

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9600)
<!-- Reviewable:end -->
2016-02-16 23:13:55 +05:30
bors-servo
f0d4c03bd9 Auto merge of #9636 - nox:mv-cursor, r=Ms2ger
Move util::cursor to style_traits

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9636)
<!-- Reviewable:end -->
2016-02-16 16:50:20 +05:30
Paul Rouget
76f63c3569 Follow executable symlink to resolve resources directory 2016-02-16 19:12:55 +08:00
Anthony Ramine
290694b27e Move util::cursor to style_traits 2016-02-16 00:50:01 +01:00
Jayflux
d169d7bd9e refactor, moving functions into attr and htmlfontelemend fixes #9639 #9638 2016-02-15 22:33:14 +00:00
bors-servo
024d106f78 Auto merge of #9635 - nox:mv-bezier, r=jdm
Move util::bezier to style

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9635)
<!-- Reviewable:end -->
2016-02-15 07:47:27 +05:30
Peter
f374e8f420 #9640 Refactor: Move util::str::is_token to script::dom::bindings::str 2016-02-14 22:47:52 +00:00
Anthony Ramine
09f865919d Move util::bezier to style 2016-02-14 19:45:24 +01:00
Emilio Cobos Álvarez
dd503dfacb Refactor style to be completely backend-independent
This commit refactors the style crate to be completely independent of
the actual implementation and pseudo-elements supported.

This also adds a gecko backend which introduces parsing for the
anonymous box pseudo-elements[1], although there's still no way of
querying them.

https://mxr.mozilla.org/mozilla-central/source/layout/style/nsCSSAnonBoxList.h
2016-02-13 16:05:14 +01:00
Anthony Ramine
55dcee94be Bump heapsize to 0.3 2016-02-13 11:13:19 +01:00
Anthony Ramine
680c817d53 Bump url to 0.5.5 2016-02-13 00:08:12 +01:00
Anthony Ramine
899a5bbfa4 Bump selectors to 0.4.1 2016-02-13 00:08:11 +01:00
Anthony Ramine
874fa5595f Bump euclid to 0.6.2 2016-02-13 00:08:08 +01:00
Anthony Ramine
d0ab28a735 Bump cssparser to 0.5.3 2016-02-13 00:08:07 +01:00
Anthony Ramine
e2d9734609 Bump string_cache to 0.2.9 2016-02-13 00:08:06 +01:00
Anthony Ramine
2d6ac4da97 Bump app_units to 0.2.1 2016-02-13 00:08:05 +01:00
Daniel Robertson
4d38b82582 Add error messages when parsing opts returns error
Provide additional error messages when parsing command line option
returns an error.
2016-02-10 23:13:15 -05:00
Ms2ger
7e7683740a Remove some unused dependencies from the util crate. 2016-02-05 13:06:14 +01:00
bors-servo
87aaa5ffe0 Auto merge of #9523 - ruud-v-a:hasher, r=Wafflespeanut
Upgrade to new Hasher API

This fixes #9494.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9523)
<!-- Reviewable:end -->
2016-02-05 07:32:13 +05:30
Anthony Ramine
cb5cd8d881 Say farewell to in-tree HeapSizeOf 2016-02-04 22:03:32 +01:00
Anthony Ramine
df2a3c3bc3 Bump html5ever to 0.4.2 2016-02-04 14:21:08 +01:00
Anthony Ramine
5bb3fc395a Bump cssparser to 0.5.2 2016-02-04 14:14:23 +01:00
Anthony Ramine
1da19170d2 Bump string_cache to 0.2.7 2016-02-04 14:10:02 +01:00
Anthony Ramine
32bc3d9c09 Reorder dependencies in various Cargo.toml files 2016-02-04 14:09:01 +01:00
Ms2ger
2ea9f2d028 Update Euclid. 2016-02-04 11:02:09 +01:00
Ruud van Asseldonk
95be0b9a25 Upgrade to new Hasher API 2016-02-03 20:06:39 +01:00
bors-servo
64ad9e17d9 Auto merge of #9498 - KiChjang:update-url, r=nox
Update rust-url

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9498)
<!-- Reviewable:end -->
2016-02-03 11:38:51 +05:30
Emilio Cobos Álvarez
a1c830f1c1 Update rust-selectors
This commits updates rust-selectors to use the generic parser, and as
such it moves the element state into the style crate.
2016-02-03 02:11:31 +01:00
Keith Yeung
9b23839394 Update rust-url 2016-02-02 20:04:01 -05:00
Anthony Ramine
436b952298 Bump Rust to 2016-01-31 nightly 2016-02-01 17:55:36 +01:00
Simon Sapin
c7b51e7aa1 Update html5ever and xml5ever for API changes. 2016-01-27 12:25:16 +01:00
bors-servo
e74021baaa Auto merge of #9400 - jmr0:websocket, r=nox
Fixing websocket subprotocol header validation

This takes care of https://github.com/servo/servo/issues/9034

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9400)
<!-- Reviewable:end -->
2016-01-25 17:01:39 +05:30
jmr0
3846cf52f2 fix websocket header validation, ensure it meets token requirements, add
testing
2016-01-24 18:31:21 -05:00
bors-servo
525e77f64f Auto merge of #9385 - larsbergstrom:win32, r=frewsxcv,pcwalton,jdm,ecoal95
Win32 support

r? @frewsxcv for python stuff
r? @pcwalton for the "remove usage of Gaol" stuff for Win32
r? anybody else for misc cargo.lock updates, etc.

This replaces #7878.

This works best with https://github.com/servo/mozjs/pull/71, too, to enable static linking, but can be run without (via some PATH hackery).

The instructions are here, and will be added to a .md file in the repo once the mozjs changes also land:
https://hackpad.com/Servo-on-Windows-C1LPcI2bP25

I'd like to get these changes landed because I've been rebasing them for months, they're otherwise quite stable, and don't affect our other platforms and targets.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9385)
<!-- Reviewable:end -->
2016-01-23 07:27:27 +05:30
Lars Bergstrom
e9d9d1d9e9 Cargo.lock updates 2016-01-22 19:28:46 -06:00
Simon Sapin
6fd46b5e6a Update cssparser.
https://github.com/servo/rust-cssparser/pull/91
2016-01-21 17:58:03 +01:00
Lars Bergstrom
095658e098 Cargo updates and small workqueue change 2016-01-20 08:38:27 -06:00
Vladimir Vukicevic
5e136d6dd5 win32: make sleep_microseconds for backoff just do a win32 Sleep(0) 2016-01-20 08:38:22 -06:00
St.Spyder
763b99258f Update XHR BodyInit, update extract method impl 2016-01-18 02:26:13 +05:30
Emilio Cobos Álvarez
92d7c49924 codegen: Implement WebIDL sequence arguments 2016-01-12 18:25:46 +01:00
Bobby Holley
dec296ddbc Use features to prevent the util component from entraining the world in GeckoLib builds. 2016-01-11 19:38:43 -08:00
bors-servo
d3e2f94f20 Auto merge of #9201 - wenderen:8512-task-thread, r=jdm
task -> thread

for #8512

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9201)
<!-- Reviewable:end -->
2016-01-10 15:49:04 +05:30
rohan.prinja
1f02c4ebbb task -> thread 2016-01-10 17:58:13 +09:00
bors-servo
aa713c9fbb Auto merge of #9209 - bholley:geckolib, r=SimonSapin
Implement a geckolib target

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9209)
<!-- Reviewable:end -->
2016-01-10 07:14:17 +05:30
Bobby Holley
840df61ba3 Implement a geckolib target. 2016-01-09 12:37:56 -08:00
Matt Brubeck
bfed072faa Remove unimplemented -Z profile-tasks option 2016-01-08 14:16:19 -08:00
Johannes Linke
6b215f38ee Fix a bunch of clippy lints 2016-01-02 23:27:15 +01:00
Josh Matthews
cca25e2b3a Enable MIME sniffing via a pref instead of a global option. 2015-12-31 07:45:49 -05:00
bors-servo
0f5c614609 Auto merge of #9051 - bholley:split_style_and_layout_wrappers, r=SimonSapin
Split layout wrappers into style+layout and layout-only functionality

This is a step towards removing the dependency of stylo on layout/.

This PR depends on #9004.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9051)
<!-- Reviewable:end -->
2015-12-30 10:04:14 +05:30