gecko-dev/servo/components/script
Imanol Fernandez f0a769c439 servo: Merge #19007 - Fix Const IDL value compilation errors in codegen (from MortimerGoro:const_codegen); r=emilio
<!-- Please describe your changes on the following line: -->

I found that some const WebIDL values fail at rust compile time.

Example:

const long long TIMEOUT_IGNORED  = -1;

```
906 |     ConstantSpec { name: b"TIMEOUT_IGNORED\0", value: ConstantVal::DoubleVal(-1) }]
    |                                                                              ^^ expected f64, found integral variable
    |
    = note: expected type `f64`
               found type `{integer}`
```

I added a explicit cast to to fix the problem in conversions that may fail to compile.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [ ] These changes fix #__ (github issue number if applicable).

<!-- Either: -->
- [x] There are tests for these changes OR
- [ ] These changes do not require tests because _____

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

Source-Repo: https://github.com/servo/servo
Source-Revision: 6449c00fc95c2aebe5b8322a70018d3664941d77

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : a8a33bef389d77715c9dc87acce437bacd3a5322
2017-10-25 06:48:43 -05:00
..
docs servo: Merge #18635 - Rename JS<T> to Dom<T>, Root<T> to DomRoot<T>, and other things (from servo:RENAME-ALL-THE-THINGS); r=emilio 2017-09-26 03:20:05 -05:00
dom servo: Merge #19007 - Fix Const IDL value compilation errors in codegen (from MortimerGoro:const_codegen); r=emilio 2017-10-25 06:48:43 -05:00
task_source servo: Merge #18900 - Remove use of unstable box syntax (from servo:box_syntax); r=emilio 2017-10-16 11:21:21 -05:00
body.rs servo: Merge #18938 - Replace all uses of the heapsize crate with malloc_size_of (from nnethercote:bug-1409255); r=SimonSapin 2017-10-18 13:56:05 -05:00
build.rs servo: Merge #18971 - Use env::var_os to read paths from the environment (from mbrubeck:var); r=emilio 2017-10-21 08:09:22 -05:00
Cargo.toml servo: Merge #18973 - Update offscreen_gl_context to v0.12 (from MortimerGoro:offscreen_v12); r=jdm 2017-10-21 05:08:58 -05:00
clipboard_provider.rs servo: Merge #17425 - cleanup embedder/compositor/constellation/script messages (from paulrouget:attach-pipeline-2); r=asajeffrey 2017-08-15 02:20:10 -05:00
CMakeLists.txt servo: Merge #13410 - Fix doc build by resurrecting generation of supported DOM APIs.h (from jdm:doc_fix); r=Ms2ger 2016-09-26 23:33:53 -05:00
devtools.rs Backed out changeset e64e659c077d: servo PR #18809 and revendor for reftest failures, e.g. in layout/reftests/bugs/392435-1.html. r=backout on a CLOSED TREE 2017-10-19 23:23:30 +02:00
document_loader.rs servo: Merge #18938 - Replace all uses of the heapsize crate with malloc_size_of (from nnethercote:bug-1409255); r=SimonSapin 2017-10-18 13:56:05 -05:00
fetch.rs servo: Merge #18981 - Merge request type and destination (from KiChjang:fold-type-destination); r=avadacatavra 2017-10-24 17:02:18 -05:00
layout_image.rs servo: Merge #18981 - Merge request type and destination (from KiChjang:fold-type-destination); r=avadacatavra 2017-10-24 17:02:18 -05:00
lib.rs Backed out changeset e64e659c077d: servo PR #18809 and revendor for reftest failures, e.g. in layout/reftests/bugs/392435-1.html. r=backout on a CLOSED TREE 2017-10-19 23:23:30 +02:00
mem.rs servo: Merge #18938 - Replace all uses of the heapsize crate with malloc_size_of (from nnethercote:bug-1409255); r=SimonSapin 2017-10-18 13:56:05 -05:00
microtask.rs servo: Merge #18938 - Replace all uses of the heapsize crate with malloc_size_of (from nnethercote:bug-1409255); r=SimonSapin 2017-10-18 13:56:05 -05:00
network_listener.rs servo: Merge #18573 - Introduce TaskOnce (from servo:TASKS); r=SimonSapin 2017-09-20 05:17:12 -05:00
script_runtime.rs servo: Merge #18952 - Do not trace Rust values when thread is shutting down (from jdm:no-leak-on-shutdown); r=nox 2017-10-20 20:28:03 -05:00
script_thread.rs servo: Merge #18968 - Use try syntax for Option where appropriate (from mbrubeck:try); r=emilio 2017-10-21 03:31:21 -05:00
serviceworker_manager.rs servo: Merge #17749 - Extra space check (from SergeevPavel:extra-space-check); r=jdm 2017-07-19 16:03:51 -07:00
serviceworkerjob.rs servo: Merge #18635 - Rename JS<T> to Dom<T>, Root<T> to DomRoot<T>, and other things (from servo:RENAME-ALL-THE-THINGS); r=emilio 2017-09-26 03:20:05 -05:00
stylesheet_loader.rs servo: Merge #18981 - Merge request type and destination (from KiChjang:fold-type-destination); r=avadacatavra 2017-10-24 17:02:18 -05:00
task.rs servo: Merge #18875 - Remove the need for rust-mozjs to use unstable Rust features (from servo:stable-js); r=nox,jdm 2017-10-16 17:07:50 -05:00
test.rs servo: Merge #18716 - Parse srcset attribute values (from jdm:parseSrcset); r=jdm 2017-10-04 07:32:53 -05:00
textinput.rs Backed out changeset e64e659c077d: servo PR #18809 and revendor for reftest failures, e.g. in layout/reftests/bugs/392435-1.html. r=backout on a CLOSED TREE 2017-10-19 23:23:30 +02:00
timers.rs servo: Merge #18938 - Replace all uses of the heapsize crate with malloc_size_of (from nnethercote:bug-1409255); r=SimonSapin 2017-10-18 13:56:05 -05:00
unpremultiplytable.rs
webdriver_handlers.rs servo: Merge #18635 - Rename JS<T> to Dom<T>, Root<T> to DomRoot<T>, and other things (from servo:RENAME-ALL-THE-THINGS); r=emilio 2017-09-26 03:20:05 -05:00