Azure / Azure/azure-sdk-tools

APIView wrongfully treating some `std::vector<>` members as `int` members.

Open
#1,309 1 comment 0 reactions 0 assignees View on GitHub
Client
Dominant language
C#
Stars
135
Forks
260
Avg merge
3d 1h
Merged PRs (30d)
144

Description

Source: https://apiview.dev/Assemblies/Review/5aec114a35f946ba9ee31e0955b69fea

Search for `Response CommitBlockList`.
`const int & blockIds, ` is shown, however the code is:
https://github.com/Azure/azure-sdk-for-cpp/blob/master/sdk/storage/azure-storage-blobs/inc/azure/storage/blobs/block_blob_client.hpp#L201
`const std::vector& blockIds,`

Command used:

DataLake:

clang++ .\sdk\storage\azure-storage-files-datalake\inc\azure\storage\files\datalake.hpp -I .\sdk\storage\azure-storage-files-datalake\inc -I .\sdk\core\azure-core\inc -Xclang -ast-dump -I .\sdk\storage\azure-storage-common\inc -I .\sdk\storage\azure-storage-blobs\inc > Azure_Storage_Files_Datalake.ast

Compress-Archive Azure_Storage_Files_Datalake.ast -DestinationPath Azure_Storage_Files_Datalake.zip

Rename-Item Azure_Storage_Files_Datalake.zip -NewName Azure_Storage_Files_Datalake.cppast

File:

clang++ .\sdk\storage\azure-storage-files-shares\inc\azure\storage\files\shares.hpp -I .\sdk\storage\azure-storage-files-shares\inc -I .\sdk\core\azure-core\inc -Xclang -ast-dump -I .\sdk\storage\azure-storage-common\inc > Azure_Storage_Files_Shares.ast

Compress-Archive Azure_Storage_Files_Shares.ast -DestinationPath Azure_Storage_Files_Shares.zip

Rename-Item Azure_Storage_Files_Shares.zip -NewName Azure_Storage_Files_Shares.cppast

Blob:

clang++ .\sdk\storage\azure-storage-blobs\inc\azure\storage\blobs.hpp -I .\sdk\storage\azure-storage-blobs\inc -I .\sdk\core\azure-core\inc -Xclang -ast-dump -I .\sdk\storage\azure-storage-common\inc > Azure_Storage_Blobs.ast

Compress-Archive Azure_Storage_Blobs.ast -DestinationPath Azure_Storage_Blobs.zip

Rename-Item Azure_Storage_Blobs.zip -NewName Azure_Storage_Blobs.cppast

Contributor guide

Open the contributing guide

Research direction

Start with the APIView review and the declaration of CommitBlockList in sdk/storage/azure-storage-blobs/inc/azure/storage/blobs/block_blob_client.hpp around line 201. Reproduce the generated AST inputs using the clang++ commands in the issue, then compare the APIView type output with const std::vector& blockIds. Done means this member is no longer displayed as const int&.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.