aboutsummaryrefslogtreecommitdiffstats
path: root/components/script_layout_interface
diff options
context:
space:
mode:
Diffstat (limited to 'components/script_layout_interface')
-rw-r--r--components/script_layout_interface/Cargo.toml2
-rw-r--r--components/script_layout_interface/reporter.rs16
2 files changed, 7 insertions, 11 deletions
diff --git a/components/script_layout_interface/Cargo.toml b/components/script_layout_interface/Cargo.toml
index 1de8502117e..e26942f0d31 100644
--- a/components/script_layout_interface/Cargo.toml
+++ b/components/script_layout_interface/Cargo.toml
@@ -13,7 +13,7 @@ path = "lib.rs"
app_units = "0.5"
atomic_refcell = "0.1"
canvas_traits = {path = "../canvas_traits"}
-cssparser = "0.18"
+cssparser = "0.19"
euclid = "0.15"
gfx_traits = {path = "../gfx_traits"}
heapsize = "0.4"
diff --git a/components/script_layout_interface/reporter.rs b/components/script_layout_interface/reporter.rs
index ec3dfae91a9..1e8462603bc 100644
--- a/components/script_layout_interface/reporter.rs
+++ b/components/script_layout_interface/reporter.rs
@@ -2,7 +2,7 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
-use cssparser::{Parser, SourcePosition};
+use cssparser::SourceLocation;
use ipc_channel::ipc::IpcSender;
use log;
use msg::constellation_msg::PipelineId;
@@ -22,18 +22,14 @@ pub struct CSSErrorReporter {
}
impl ParseErrorReporter for CSSErrorReporter {
- fn report_error<'a>(&self,
- input: &mut Parser,
- position: SourcePosition,
- error: ContextualParseError<'a>,
- url: &ServoUrl,
- line_number_offset: u64) {
- let location = input.source_location(position);
- let line_offset = location.line + line_number_offset as u32;
+ fn report_error(&self,
+ url: &ServoUrl,
+ location: SourceLocation,
+ error: ContextualParseError) {
if log_enabled!(log::LogLevel::Info) {
info!("Url:\t{}\n{}:{} {}",
url.as_str(),
- line_offset,
+ location.line,
location.column,
error.to_string())
}