| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2013, the Dart project authors. | 2 * Copyright (c) 2013, the Dart project authors. |
| 3 * | 3 * |
| 4 * Licensed under the Eclipse Public License v1.0 (the "License"); you may not u
se this file except | 4 * Licensed under the Eclipse Public License v1.0 (the "License"); you may not u
se this file except |
| 5 * in compliance with the License. You may obtain a copy of the License at | 5 * in compliance with the License. You may obtain a copy of the License at |
| 6 * | 6 * |
| 7 * http://www.eclipse.org/legal/epl-v10.html | 7 * http://www.eclipse.org/legal/epl-v10.html |
| 8 * | 8 * |
| 9 * Unless required by applicable law or agreed to in writing, software distribut
ed under the License | 9 * Unless required by applicable law or agreed to in writing, software distribut
ed under the License |
| 10 * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY K
IND, either express | 10 * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY K
IND, either express |
| (...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 251 " void x() {}", | 251 " void x() {}", |
| 252 "}")); | 252 "}")); |
| 253 resolve(source); | 253 resolve(source); |
| 254 assertErrors(source, CompileTimeErrorCode.CONFLICTING_CONSTRUCTOR_NAME_AND_M
ETHOD); | 254 assertErrors(source, CompileTimeErrorCode.CONFLICTING_CONSTRUCTOR_NAME_AND_M
ETHOD); |
| 255 verify(source); | 255 verify(source); |
| 256 } | 256 } |
| 257 | 257 |
| 258 public void test_conflictingGetterAndMethod_field_method() throws Exception { | 258 public void test_conflictingGetterAndMethod_field_method() throws Exception { |
| 259 Source source = addSource(createSource(// | 259 Source source = addSource(createSource(// |
| 260 "class A {", | 260 "class A {", |
| 261 " int m;", | 261 " final int m = 0;", |
| 262 "}", | 262 "}", |
| 263 "class B extends A {", | 263 "class B extends A {", |
| 264 " m() {}", | 264 " m() {}", |
| 265 "}")); | 265 "}")); |
| 266 resolve(source); | 266 resolve(source); |
| 267 assertErrors(source, CompileTimeErrorCode.CONFLICTING_GETTER_AND_METHOD); | 267 assertErrors(source, CompileTimeErrorCode.CONFLICTING_GETTER_AND_METHOD); |
| 268 verify(source); | 268 verify(source); |
| 269 } | 269 } |
| 270 | 270 |
| 271 public void test_conflictingGetterAndMethod_getter_method() throws Exception { | 271 public void test_conflictingGetterAndMethod_getter_method() throws Exception { |
| (...skipping 3438 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3710 assertErrors(source, CompileTimeErrorCode.WRONG_NUMBER_OF_PARAMETERS_FOR_OPE
RATOR); | 3710 assertErrors(source, CompileTimeErrorCode.WRONG_NUMBER_OF_PARAMETERS_FOR_OPE
RATOR); |
| 3711 verify(source); | 3711 verify(source); |
| 3712 reset(); | 3712 reset(); |
| 3713 } | 3713 } |
| 3714 | 3714 |
| 3715 private void check_wrongNumberOfParametersForOperator1(String name) throws Exc
eption { | 3715 private void check_wrongNumberOfParametersForOperator1(String name) throws Exc
eption { |
| 3716 check_wrongNumberOfParametersForOperator(name, ""); | 3716 check_wrongNumberOfParametersForOperator(name, ""); |
| 3717 check_wrongNumberOfParametersForOperator(name, "a, b"); | 3717 check_wrongNumberOfParametersForOperator(name, "a, b"); |
| 3718 } | 3718 } |
| 3719 } | 3719 } |
| OLD | NEW |