Skip to content
This repository was archived by the owner on Sep 30, 2024. It is now read-only.
This repository was archived by the owner on Sep 30, 2024. It is now read-only.

Allow use of unchecked keyword to declare unchecked arrays? #22

@secure-sw-dev-bot

Description

@secure-sw-dev-bot

This issue was copied from checkedc/checkedc#22


When an array declarator is declared to be checked, by default the checked property propagates to directly-nested array types. This is provided that the nested array types are declared as part of the declarator.

For example, int a checked[10][10]; declares a checked array of checked arrays. This should be thought of as syntactic shorthand for int a checked[10]checked[10]. In contrast, typedef int myarr[10]; myarr a checked[10] declares a checked array of unchecked arrays.

For the purposes of language completeness, it might be useful to allow programmers to declare an array to be unchecked. We don't recommend mixing checked arrays and unchecked arrays in multi-dimensional array declaration, but in incrementally converting code, the need for this come up. To do this, we might allow an array declarator to be prefixed by the 'unchecked' keyword.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestquestionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions