Commit graph

5393 commits

Author SHA1 Message Date
Josh Matthews
bba4bef106 Merge pull request #2296 from Ms2ger/update-opengles
Update rust-opengles.
2014-05-05 10:13:42 -04:00
bors-servo
f642d5951a auto merge of #2299 : Ms2ger/servo/getJSToNativeConversionTemplate-cleanup, r=jdm 2014-05-05 09:43:18 -04:00
Ms2ger
6cab06fee6 Use default methods to reduce code duplication for TestBinding. 2014-05-05 15:39:28 +02:00
bors-servo
edb1547502 auto merge of #2323 : Manishearth/servo/warnings, r=Ms2ger
The `.encode()`s from where the unused_result warnings come from seem to wrap an `encode()` and return `Ok(())`.

They should probably bubble the result out.
2014-05-05 06:19:21 -04:00
Manish Goregaokar
1008a536a7 Fix some unused_mut/unused_result warnings 2014-05-05 15:43:29 +05:30
Ms2ger
262dc30c18 Assign into the argument binding directly in instantiateJSToNativeConversionTemplate. 2014-05-05 11:36:52 +02:00
Ms2ger
aed95dfd94 Move the assignment outside the if when dealing with optional arguments. 2014-05-05 11:36:52 +02:00
Ms2ger
d14efebb5c Move the assignment of 'None' in the no-argument-passed case into an else branch.
This is the only case where we assign into an argument local twice, so removing
it will allow us to make that binding immutable.
2014-05-05 11:36:52 +02:00
Ms2ger
cb2723c4ed Remove getJSToNativeConversionTemplate's initialValue return value.
This commit does not change the generated code.
2014-05-05 11:36:49 +02:00
Ms2ger
455465f3c6 Move the handling of default values in getJSToNativeConversionTemplate into handleOptional.
This is a first step towards moving responsibility for default values into the
caller, which should improve their code (in particular for the dictionary
codegen.

This also introduces a Dictionary::empty function, whose implementation is a
hack. The implementation will be improved once its codegen has access to the
raw default values.

Besides dictionaries, this commit does not change the generated code.
2014-05-05 11:29:46 +02:00
Ms2ger
e53c768b9e Use CGIfWrapper in instantiateJSToNativeConversionTemplate. 2014-05-05 11:21:13 +02:00
Ms2ger
2db1ce72f0 Remove references to unused substitution variables in getJSToNativeConversionTemplate. 2014-05-05 11:21:13 +02:00
bors-servo
310d2a19bb auto merge of #2320 : glennw/servo/codegen-warnings, r=jdm
Is it reasonable to always expect success here for now?

Fixes #2246.
2014-05-05 01:22:17 -04:00
bors-servo
150de252de auto merge of #2316 : Ms2ger/servo/owned-str-tests, r=jdm 2014-05-05 00:52:21 -04:00
Glenn Watson
71f3f5894e Prevent unused result warning in codegen. Always expect success for now. 2014-05-05 11:04:05 +10:00
bors-servo
67c9883d9a auto merge of #2317 : Ms2ger/servo/rebased-vec, r=Ms2ger
#2271 rebased.
2014-05-04 17:25:39 -04:00
Matt Murphy
8b94a44c0b Changes based on review 2014-05-04 23:16:18 +02:00
Matt Murphy
af920f442b Convert Vec::new() to vec!() 2014-05-04 23:16:18 +02:00
Matt Murphy
4d595b7d8c ~[] to Vec in harness/contenttest/contenttest.rs 2014-05-04 23:16:18 +02:00
Matt Murphy
c174a40afd ~[] to Vec in net/resource_task.rs 2014-05-04 23:16:18 +02:00
Matt Murphy
631f70b1c5 ~[] to Vec in util/cache.rs 2014-05-04 23:16:18 +02:00
Matt Murphy
33d0a3af09 ~[] to Vec in style/selectors.rs 2014-05-04 23:16:18 +02:00
Matt Murphy
544bbcde92 ~[] to Vec in util/time.rs 2014-05-04 23:16:17 +02:00
Matt Murphy
428ea04fb5 ~[] to Vec in script/script_task.rs 2014-05-04 23:16:17 +02:00
Matt Murphy
e107d0f015 ~[] to Vec in script/script_task.rs 2014-05-04 23:16:17 +02:00
Matt Murphy
dccea25a8a ~[] to Vec in script/html/hubbub_html_parser.rs 2014-05-04 23:16:17 +02:00
Matt Murphy
093e9fdd19 ~[] to Vec in style/properties.rs.mako and selector_matching.rs 2014-05-04 23:16:17 +02:00
Matt Murphy
58bbe651a0 ~[] to Vec in script/dom/node.rs 2014-05-04 23:16:17 +02:00
Matt Murphy
b88c84dde8 ~[] to Vec in gfx/text/text_run.rs 2014-05-04 23:16:17 +02:00
Matt Murphy
2903e55de0 ~[] to Vec in gfx/text/shaping/harfbuzz.rs 2014-05-04 23:16:17 +02:00
Matt Murphy
f32d1f007f ~[] to std::vec::Vec in gfx/text/glyph.rs 2014-05-04 23:16:17 +02:00
Matt Murphy
f219dbeb6f ~[] to Vec in gfx/font_list.rs 2014-05-04 23:16:17 +02:00
Matt Murphy
98a78e3faf ~[] to Vec in glut_windowing 2014-05-04 23:16:17 +02:00
Matt Murphy
81fd243f37 ~[] to Vec in glfw_windowing and servo 2014-05-04 23:16:17 +02:00
Matt Murphy
7605464c24 ~[] to Vec in table, table_colgroup, and text 2014-05-04 23:16:16 +02:00
Matt Murphy
e761649cda ~[] to Vec in layout flow, block, table, row, rowgroup, wrapper 2014-05-04 23:16:16 +02:00
Matt Murphy
3d1a885a55 ~[] to Vec in main 2014-05-04 23:16:16 +02:00
Matt Murphy
6522e7827d ~[] to Vec in main/constellation.rs 2014-05-04 23:16:16 +02:00
Matt Murphy
7073f3b645 ~[] to Vec in main/compositing/compositor_layer.rs 2014-05-04 23:16:16 +02:00
Matt Murphy
60d443da16 ~[] to Vec in main/layout/wrapper.rs 2014-05-04 23:16:16 +02:00
Matt Murphy
3a8ecb2bb1 ~[] to Vec in main/layout/layout_task.rs, script/dom/clientrectlist.rs,
script/layout_interface.rs
2014-05-04 23:16:16 +02:00
Matt Murphy
36fdcdc929 ~[] to Vec in main/layout/box_.rs, gfx/text/util.rs, main/layout/text.rs 2014-05-04 23:16:16 +02:00
Matt Murphy
62bbe1f555 ~[] to Vec in main/layout/construct.rs and associated files 2014-05-04 23:16:16 +02:00
Matt Murphy
8da47b6a32 ~[] to std::vec::Vec in layout 2014-05-04 23:16:16 +02:00
Matt Murphy
d734a8937d ~[] to Vec in main/compositing and associated files 2014-05-04 23:16:16 +02:00
Matt Murphy
f2707bc405 ~[] to Vec in style/media_quieres.rs, selectors.rs, stylesheets.rs 2014-05-04 23:16:15 +02:00
Matt Murphy
7447ed69e3 ~[] to Vec in FontStyle and FontGroup 2014-05-04 23:16:15 +02:00
Ms2ger
cde01affcd Use str.to_owned() in tests. 2014-05-04 20:12:58 +02:00
bors-servo
b1d0dac50d auto merge of #2312 : Ms2ger/servo/owned-strings, r=SimonSapin 2014-05-04 06:22:21 -04:00
Ms2ger
11ea7d4935 Call find_equiv to avoid allocation strings. 2014-05-04 10:17:32 +02:00