Brandon Fairchild
d61a6e2161
Fix reported test-tidy errors
...
This fixes lines that were reported to have missing
space after a comma.
2015-09-01 16:30:42 -04:00
Corey Farwell
3a1d140ab5
Enforce linking to spec for method implementations via macros
2015-08-31 21:02:23 -04:00
wilmoz
64ac4f175f
Make test-tidy check that braces have spaces before or after them
2015-08-31 12:30:55 -05:00
benshu
1e6a2f08fc
Time distribution across script event categories.
2015-08-28 00:52:41 +02:00
Anthony Ramine
709d347872
Make the traits for the IDL interfaces take &self
2015-08-27 22:27:43 +02:00
Anthony Ramine
c831c2c0a5
Remove helper traits
...
Now that JSRef<T> is gone, there is no need to have helper traits.
On components/script/*.rs:
# Remove imports.
/^ *use dom::[a-z]+::\{.*Helpers/ {
s/\{(Raw[^L]|[^L][^a])[a-zA-Z]+Helpers, /\{/
s/, (Raw[^L]|[^L][^a])[a-zA-Z]+Helpers([,}])/\2/g
s/\{([a-zA-Z]+)\}/\1/
/\{\}/d
s/::self;$/;/
}
/^ *use dom::[a-z]+::\{?(Raw[^L]|[^L][^a])[a-zA-Z]+Helpers\}?;$/d
On components/script/dom/*.rs:
# Ignore layout things.
/^(pub )?(impl|trait).*Layout.* \{/,/^}$/ { P; D; }
# Delete helpers traits.
/^(pub )?trait ([^L][^ ]|L[^a])[^ ]+Helpers(<'a>)? \{$/,/^\}$/D
# Patch private helpers.
/^impl.*Private.*Helpers/,/^\}$/ {
s/^impl<'a> Private([^L][^ ]|L[^a])[^ ]+Helpers(<'a>)? for &'a ([^ ]+) \{$/impl \3 {/
/^ *(unsafe )?fn .*\(self.*[<&]'a/ {
s/&'a /\&/g
s/<'a, /</g
}
/^ *(unsafe )?fn /s/\(self([,)])/\(\&self\1/
}
# Patch public helpers.
/^impl.*Helpers/,/^\}$/ {
s/^impl(<'a>)? ([^L][^ ]|L[^a])[^ ]+Helpers(<'a>)? for (&'a )?([^ ]+) \{$/impl \5 {/
/^ *(unsafe )?fn .*\(self.*[<&]'a/ {
s/&'a /\&/g
s/<'a, /</g
}
/^ *(unsafe )?fn .*\(&?self[,)]/s/(unsafe )?fn/pub &/
/^ *pub (unsafe )?fn /s/\(self([,)])/\(\&self\1/
}
The few error cases were then fixed by hand.
2015-08-27 16:59:02 +02:00
João Oliveira
fd87c8cb3e
make dom_struct derive HeapSizeOf,
...
closes #7357
2015-08-27 01:17:48 +01:00
Johann Tuffe
ec07178b6f
sort all uses
2015-08-20 20:47:12 +08:00
Manish Goregaokar
5c4f91c0f1
Cleanup Window, XHR
2015-08-18 18:38:32 +05:30
Josh Matthews
8bb853f643
Fix existing syntactics nits.
2015-08-16 10:30:43 -04:00
bors-servo
6a52ec9484
Auto merge of #7006 - Wafflespeanut:script_cleanup, r=jdm
...
Splitting ScriptMsg into various enums...
... for #3734 , which is also one of the oldest issues. (/cc @jdm)
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png " height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/7006 )
<!-- Reviewable:end -->
2015-08-15 03:48:47 -06:00
João Oliveira
0038580abf
Replace uses of for foo in bar.iter()
and for foo in bar.iter_mut()
...
closes #7197
2015-08-15 02:27:39 +01:00
Ravi Shankar
89153116fb
Splitting ScriptMsg into various enums; r=jdm
2015-08-15 02:00:48 +05:30
João Oliveira
9c11781880
replace .len() == 0 with is_empty()
...
closes #7198
2015-08-14 04:00:33 +01:00
Bogdan Cuza
45145108da
Measure heap memory usage for more types. Fixes #6951
2015-08-13 21:44:41 +03:00
Patrick Walton
2aa5174246
script: Make the resource task communication use IPC channels.
2015-07-31 11:28:09 -07:00
Patrick Walton
44d13f7fd4
net: Use a thread for each AsyncResponseTarget
to avoid having to send
...
trait objects across process boundaries.
2015-07-31 11:27:49 -07:00
Patrick Walton
9c9d7dc93b
net: Make most of the resource task messages serializable.
2015-07-31 11:27:49 -07:00
Bogdan Cuza
233a769c67
Add spec links
2015-07-28 13:28:41 +02:00
Bogdan Cuza
68d574bc32
Fix #6674
2015-07-22 16:45:44 +03:00
Simon Sapin
83d2a11d86
Upgrade to rustc 1.3.0-dev (fddfd089b 2015-07-10)
2015-07-15 00:46:43 +02:00
David Zbarsky
bc1eb97671
Remove some more unnecessary let bindings
2015-07-14 14:48:16 -04:00
David Winslow
4cf46bff2d
Refactor #[jstraceable] to #[derive(JSTraceable)]
...
fixes #6524
2015-07-01 18:27:06 -04:00
Michael Wu
675267b782
Upgrade to SM 39
2015-06-19 18:42:48 -04:00
Ms2ger
b49bd79625
Use str::parse() rather than FromStr::from_str.
...
The former appears to be preferred.
2015-06-13 17:58:16 +02:00
Anthony Ramine
6802bafc39
Cleanup URLSearchParams
...
It now uses rust-url for its serializer.
2015-05-27 12:19:16 +02:00
Himaja
01eb31ae8a
1. Add an Option<Pipeline_id> field to the LoadData struct, and a corresponding parameter to LoadData::new()
...
2. Change addEvent in the NetworkEventActor to add_request and add_response
2015-05-05 12:31:40 -04:00
Simon Sapin
ef8edd4e87
Upgrade to rustc 551a74dddd84cf01440ee84148ebd18bc68bd7c8.
2015-05-05 10:07:34 -04:00
Ms2ger
84b1b52682
Replace ByteString::as_slice() by a Deref implementation.
2015-05-01 21:19:11 +02:00
Ms2ger
903305416a
Implement Clone for Copy types.
2015-04-28 23:31:10 +02:00
Anthony Ramine
1a30925cad
Remove Temporary::new()
...
Temporary::from_rooted() now takes an Assignable value.
2015-04-28 09:22:46 +02:00
Anthony Ramine
7197052c0d
Uniformise root() methods
...
They now live in traits Rootable, OptionalOptionalRootable, OptionalRootable
and ResultRootable.
2015-04-28 09:22:45 +02:00
Anthony Ramine
afafde5191
Change MutNullableJS<T> to MutNullableHeap<JS<T>>
2015-04-27 10:45:38 +02:00
Ms2ger
a862479ca8
Remove as_slice() calls from script.
2015-04-26 10:52:55 +02:00
Josh Matthews
1ca9ff56c8
Create easy common interface for off-thread network listeners, and remove the CORS-specific reimplementation of async networking.
2015-04-16 11:46:41 -04:00
Josh Matthews
f7ac1f1876
Remove old implementation of XHR's fetch.
2015-04-16 11:46:41 -04:00
Josh Matthews
01e66035ff
Implement sync XHR by creating and spinning on-demand event loops.
2015-04-16 11:46:40 -04:00
Josh Matthews
2ee21ddbe7
Make the fetch method only handle sync XHRs.
2015-04-16 11:46:40 -04:00
Josh Matthews
17a88f1f81
Make timeouts for async XHR post a runnable.
2015-04-16 11:46:40 -04:00
Josh Matthews
5c7be5c9c3
Make async XMLHttpRequest requests use async network events.
2015-04-16 11:46:39 -04:00
Josh Matthews
1644436557
Start switching net/ to use abstractions over channels to allow introducing non-channel communication in the future.
2015-04-16 11:46:39 -04:00
Corey Farwell
5eaa922045
Update WHATWG links to use HTTPS
...
Extracted this out of #5649
This commit was created with the following commands:
```
find . -iname "*.webidl" -type f -print0 | xargs -0 sed -i '' 's/http:\(.*\)whatwg.org/https:\1whatwg.org/g'
```
```
find . -iname "*.rs" -type f -print0 | xargs -0 sed -i '' 's/http:\(.*\)whatwg.org/https:\1whatwg.org/g'
```
2015-04-13 21:34:27 -07:00
bors-servo
036b3eaa04
auto merge of #5511 : Ms2ger/servo/int, r=jdm
2015-04-03 13:54:46 -06:00
Ms2ger
c2e81be8a5
Stop using int/uint in script.
2015-04-03 20:47:53 +02:00
Gilles Leblanc
ba36a108c1
Split out shared networking code into net_traits crate
...
Fixes #4476
2015-04-03 13:38:10 -04:00
bors-servo
699ace844c
auto merge of #5375 : frewsxcv/servo/xhr-docs, r=jdm
...
Also adding some newlines for visual separation between
functions/methods
2015-03-26 06:33:50 -06:00
Corey Farwell
14a9871792
Add comments linking XHR code to XHR specification
...
Also adding some newlines for visual separation between
functions/methods
2015-03-25 20:35:31 -04:00
Corey Farwell
ed64e6a7c6
Remove enum variant prefix in XMLHttpRequestState
...
It was originally titled XHRDone to prevent conflicts with other
variants called Done. This was done before enum namespacing landed, but
now that it has, the prefixing is not necessary.
2015-03-25 20:04:58 -04:00
Corey Farwell
5a780cb221
Stop abusing format! macro when construct a String
...
In these cases for `format!`, we're just constructing a String of the
single argument with no special format.
2015-03-22 18:54:56 -04:00
Manish Goregaokar
3479d3fa7f
Replace unsafe_blocks by unsafe_code.
2015-03-21 10:27:32 +01:00