Description
@foreach with IEnumerable cast matches string type, causing iteration over chars instead of treating as error.
Steps to Reproduce
@foreach(var item in Context.Name) {
Item: ${item}
}
If Context.Name is a string like 'Hello', it iterates H, e, l, l, o.
Solution
Add explicit string check before IEnumerable cast in ProcessForeachBlock.