1/* 2 * Copyright (c) 2023-2023 Huawei Device Co., Ltd. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16for (let i = 0, j = 0; i < 10; ++i, j += 2) { 17 console.log(i) 18 console.log(j) 19} 20 21let x = 0 22x = (++x, x++) 23 24for (let i = 0, j = 0; i < 10; ++i, j += 2) { 25 console.log(i) 26 console.log(j) 27} 28 29let x2 = 0 30++x2 31x2 = x2++ 32 33let c = () => 33; 34const a = (1, b = 2, c()); 35const r = (c(), b, 1) 36 37class Test { 38 static readonly sr = (1, c(), 2); 39 field1 = (1, 2, c()); 40 41 method() { 42 this.field1 = (c(), sr, 1); 43 } 44} 45