---
source: crates/ruff_python_parser/src/lexer.rs
expression: lex_source(source)
---
## Tokens
```
[
    (
        FStringStart,
        0..2,
        TokenFlags(
            DOUBLE_QUOTES | F_STRING,
        ),
    ),
    (
        InterpolatedStringMiddle(
            "foo ",
        ),
        2..6,
        TokenFlags(
            DOUBLE_QUOTES | F_STRING,
        ),
    ),
    (
        Lbrace,
        6..7,
    ),
    (
        Exclamation,
        7..8,
    ),
    (
        Name(
            Name("pwd"),
        ),
        8..11,
    ),
    (
        Rbrace,
        11..12,
    ),
    (
        InterpolatedStringMiddle(
            " bar",
        ),
        12..16,
        TokenFlags(
            DOUBLE_QUOTES | F_STRING,
        ),
    ),
    (
        FStringEnd,
        16..17,
        TokenFlags(
            DOUBLE_QUOTES | F_STRING,
        ),
    ),
    (
        Newline,
        17..17,
    ),
]
```
