Question: In the given code snippet, I expected the error `symbol Record not found`. But it compiled and ran fine on Visual Studio 2010 Compiler. I ran it as a C program from Visual Studio 2010 Command Prompt in the manner -

> 
> cl Record.c  
> 
>  Record 
> 
> 
> 

Now the doubt is, doesn't `typedef` check for symbols ? Does it work more like a `forward declaration` ?

```
#include "stdio.h"
#include "conio.h"

typedef struct Record R;
struct Record
{
    int a;
};

int main()
{   
    R obj = {10};
    getch();
    return 0;
}

```

Answer: 
You can always refer to undefined structures, which is a typical way to implement linked lists, after all. They just have to be defined when you want to make use of their fields.
[This page](http://h30097.www3.hp.com/docs/base_doc/DOCUMENTATION/V40F_HTML/AQTLTBTE/DOCU_024.HTM) contains some details.
`typedef` must be used after its first parameter has been defined.

```
struct Record
{
    int a;
};
typedef struct Record R;

```

or

```
typedef struct Record
{
    int a;
} R;

```

---

If you need to use `struct Record` within the struct, just use `struct Record`:

```
typedef struct Record
{
    struct Record *next;
}
typedef struct Record R;

```