Reviewed-by: Liming Gao <[email protected]>

>-----Original Message-----
>From: Zhu, Yonghong
>Sent: Friday, September 07, 2018 3:56 PM
>To: [email protected]
>Cc: Gao, Liming <[email protected]>; Kinney, Michael D
><[email protected]>; Shaw, Kevin W <[email protected]>
>Subject: [Patch] Build spec: correct the Operator used in the expression for
>Table 12
>
>Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=598
>Cc: Liming Gao <[email protected]>
>Cc: Michael Kinney <[email protected]>
>Cc: Kevin W Shaw <[email protected]>
>Contributed-under: TianoCore Contribution Agreement 1.1
>Signed-off-by: Yonghong Zhu <[email protected]>
>---
> .../82_auto-generation_process.md                  | 34 +++++++++++-----------
> README.md                                          |  1 +
> 2 files changed, 18 insertions(+), 17 deletions(-)
>
>diff --git a/8_pre-build_autogen_stage/82_auto-generation_process.md
>b/8_pre-build_autogen_stage/82_auto-generation_process.md
>index 6ce1710..9b61e0d 100644
>--- a/8_pre-build_autogen_stage/82_auto-generation_process.md
>+++ b/8_pre-build_autogen_stage/82_auto-generation_process.md
>@@ -657,15 +657,11 @@ Refer to the DSC and FDF file form specifications
>"_Conditional Directive
> Blocks_" section for additional details of how directives must be processed.
>
> #### 8.2.4.6 Expressions
>
> Expressions can be used in conditional directive comparison statements and
>in
>-value fields for PCDs in the DSC and FDF files.
>-
>-**********
>-**Note:** Expressions are not supported in the INF and DEC files.
>-**********
>+value fields for PCDs in the meta-data files.
>
> Expressions follow C relation, equality, logical and bitwise precedence and
> associativity. Not all C operators are supported, only operators in the
> following list can be used.
>
>@@ -681,22 +677,26 @@ Use of parenthesis is encouraged to remove
>ambiguity.
> Additional scripting style operators may be used in place of C operators as
> shown in the table below.
>
> ###### Table 12 Operator Precedence and Supported Operands
>
>-| Operator                                     | Use with Data Types   | Notes
>| Priority |
>-| -------------------------------------------- | --------------------- | 
>----------------------
>-----------------------------------------------------------------------------------------------
>-----------------------------------------------------------------------------------------------
>--------- | -------- |
>-| `or`, `OR`, <code>&#124;&#124;</code>        | Number, Boolean       |
>| Lowest   |
>-| `and`, `AND`, `&&`                           | Number, Boolean       |
>|          |
>-| <code>&#124;</code>                          | Number, Boolean       | 
>Bitwise OR
>|          |
>-| `^`, `xor`, `XOR`                            | Number, Boolean       | 
>Exclusive OR
>|          |
>-| `&`                                          | Number, Boolean       | 
>Bitwise AND
>|          |
>-| `==`, `!=`, `EQ`, `NE`, `IN`                 | All                   | The 
>IN operator can only be
>used to test a quoted unary literal string for membership in a list.
>|          |
>-|                                              |                       | 
>Space characters must be used before
>and after the letter operators Strings compared to boolean or numeric values
>using "==" or "EQ" will always return FALSE, while using the "!=" or "NE"
>operators will always return TRUE |          |
>-| `<=`, `>=`, `<`, `>`, `LE`, `GE`, `LT`, `GT` | All                   | 
>Space characters must
>be used before and after the letter operators.
>|          |
>-| `+`, `-`                                     | Number, Boolean       | 
>Cannot be used with
>strings - the system does not automatically do concatenation. Tools should
>report a warning message if these operators are used with both a boolean
>and number value                                      |          |
>-| `!`, `not`, `NOT`                            | Number, Boolean       |
>| Highest  |
>+| Operator                                     | Use with Data Types | Notes
>| Priority |
>+| -------------------------------------------- | ------------------- | 
>-----------------------
>--------------------------------------------------       
>-----------------------------------------
>-------------------------------- | -------- |
>+| `? :`                                        | All                 | 
>Conditional operator
>|  Lowest  |
>+| `or`, `OR`, <code>&#124;&#124;</code>        | Number, Boolean     |
>|          |
>+| `XOR`, `xor`                                 | Number, Boolean     |
>|          |
>+| `and`, `AND`, `&&`                           | Number, Boolean     |
>|          |
>+| <code>&#124;</code>                          | Number, Boolean     | 
>Bitwise OR
>|          |
>+| `^`                                          | Number, Boolean     | 
>Bitwise XOR
>|          |
>+| `&`                                          | Number, Boolean     | 
>Bitwise AND
>|          |
>+| `==`, `!=`, `EQ`, `NE`, `IN`                 | All                 | The IN 
>operator can only be
>used to test a quoted unary literal string for membership in a list.
>|          |
>+|                                              |                     | 
>Strings compared to boolean or
>numeric values using "==" or "EQ" will always return FALSE, while using the
>"!=" or "NE" operators will always return TRUE |          |
>+| `<=`, `>=`, `<`, `>`, `LE`, `GE`, `LT`, `GT` | All                 |
>|          |
>+| `<<`, `>>`                                   | Number, Boolean     |
>|          |
>+| `+`, `-`                                     | Number, Boolean     | Cannot 
>be used with
>strings - the system does not automatically do concatenation.
>|          |
>+| `*`, `/`, `%`                                | Number, Boolean     | Cannot 
>be used with
>strings                                                                        
>                                                       |          |
>+| `!`, `not`, `NOT`, `~`                       | Number, Boolean     |
>|  Highest |
>
> The `IN` operator can only be used to test a literal string against elements
> in the following global variables:
>
> **_$(FAMILY)_**
>diff --git a/README.md b/README.md
>index a370537..637a4a4 100644
>--- a/README.md
>+++ b/README.md
>@@ -226,5 +226,6 @@ Copyright (c) 2008-2017, Intel Corporation. All rights
>reserved.
> |            | Clarify structure PCD field value assignment precedence
>|               |
> |            | Update description for build handles PCDs for SKU support
>|               |
> |            | Add statement about module scoped `<Pcd*>` section override
>scope
>|               |
> |            | Add !error statement section
>|               |
> |            | [#1110](https://bugzilla.tianocore.org/show_bug.cgi?id=1110)
>Extend exclamation statement's keyword to case-insensitive
>|               |
>+|            | [#598](https://bugzilla.tianocore.org/show_bug.cgi?id=598) 
>update
>supported operators in 8.2.4.6 Expressions
>|               |
>--
>2.6.1.windows.1

_______________________________________________
edk2-devel mailing list
[email protected]
https://lists.01.org/mailman/listinfo/edk2-devel

Reply via email to