

本文為英文版的機器翻譯版本，如內容有任何歧義或不一致之處，概以英文版為準。

# 不支援的陳述式
<a name="ecma-unsupported"></a>

Amazon Lex V2 不支援下列 ECMAScript 功能。

**Topics**
+ [空白陳述式](#ecma-unsupported-empty)
+ [繼續陳述式](#ecma-unsupported-continue)
+ [Break 陳述式](#ecma-unsupported-break)
+ [傳回陳述式](#ecma-unsupported-return)
+ [擲回陳述式](#ecma-unsupported-throw)
+ [嘗試陳述式](#ecma-unsupported-try)
+ [Debugger 陳述式](#ecma-unsupported-debugger)
+ [已標記的陳述式](#ecma-unsupported-labelled)
+ [類別宣告](#ecma-unsupported-class)

## 空白陳述式
<a name="ecma-unsupported-empty"></a>

空白陳述式用於不提供任何陳述式。以下是空白陳述式的語法：

```
;
```

## 繼續陳述式
<a name="ecma-unsupported-continue"></a>

支援沒有標籤的繼續陳述式[迭代陳述式](ecma-iteration.md)。不支援具有標籤的繼續陳述式。

```
// continue with label
// this allows the program to jump to a
// labelled statement (see labelled statement below)
continue <label>;
```

## Break 陳述式
<a name="ecma-unsupported-break"></a>

支援沒有標籤的中斷陳述式[迭代陳述式](ecma-iteration.md)。不支援具有標籤的中斷陳述式。

```
// break with label
// this allows the program to break out of a
// labelled statement (see labelled statement below)
break <label>;
```

## 傳回陳述式
<a name="ecma-unsupported-return"></a>

```
return expression;
```

## 擲回陳述式
<a name="ecma-unsupported-throw"></a>

擲回陳述式用於擲回使用者定義的例外狀況。

```
throw expression;
```

## 嘗試陳述式
<a name="ecma-unsupported-try"></a>

```
try {
  statements
}
catch (expression) {
  statements
}
finally {
  statements
}
```

## Debugger 陳述式
<a name="ecma-unsupported-debugger"></a>

除錯器陳述式用於叫用環境提供的除錯功能。

```
debugger;
```

## 已標記的陳述式
<a name="ecma-unsupported-labelled"></a>

標記的陳述式可與 `break`或 `continue`陳述式搭配使用。

```
label:
   statements


// Example
let str = '';

loop1:
for (let i = 0; i < 5; i++) {
  if (i === 1) {
    continue loop1;
  }
  str = str + i;
}

console.log(str);
```

## 類別宣告
<a name="ecma-unsupported-class"></a>

```
class Rectangle {
  constructor(height, width) {
    this.height = height;
    this.width = width;
  }
}
```