802.1D (STP) and 802.1w (RSTP) are compatible. RSTP bridges will revert to regular STP operation on interfaces which have legacy STP bridges attached. The following White Paper gives more detail about RSTP and STP interaction:
Understanding Rapid Spanning Tree Protocol (802.1w)