boostorg / boostorg/algorithm

Unexpected behavior when using algorithm::trim() to remove spaces

オープン
#58 コメント 3 件 リアクション 0 件 担当者 0 名 GitHub で見る
主要言語
C++
スター
131
フォーク
117
PR マージ指標
30日以内にマージされた PR はありません

説明

The issue comes from boostorg/compute#817 where `boost::trim()` is invoked to sanitize OpenCL kernel arguments from preprocessor-generated strings. One of the failing cases taken directly from the boost compute repo is this:

```c++
two, pi // original string
[two, pi] // vector after split() using comma as delimiter
two // first element after trim()
p // second element after trim()
```
Here the `trim()` actually leave a leading space left of `pi` and slices one valid character on the right. One big BUT: this only happens to Linux cross-compiler targeting Android platform, downloaded from Android NDK page. Where as MSVC on Windows, GCC/Clang on Mac all run without problems. What might be the reason of this unexpected behavior?

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。